[Python-Dev] Re: FWD: Re: Problem w/ IDLE on Win2000

Tim Peters tim.one at comcast.net
Sat Aug 9 16:31:49 EDT 2003

[Kurt B. Kaiser]
> ...
> Does it make sense to update the spawn* docs to include a comment that
> on Windows a spawn* /path/ with embedded spaces should not be quoted,
> but an arg with embedded spaces should be decorated with double
> quotes on each end?

I don't know.  We should document something that's sure to work, but I don't
know what's sure to work on all versions of Windows, and can't make time to
try to reverse-engineer it.  The Windows docs are hopelessly ambiguous here,
and all I guessed I reverse-engineered from studying the MS CRT source code
supplied with MSVC 6.  For all I know, it differs in critical ways in VC 7
(.NET), and I found nothing to explain observed differences in spawnv()
behavior between 98SE and XP in VC6.  Typical Windows docs:

    The reason that main and WinMain cannot return Unicode strings is
    that argc, argv, and lpCmdLine use the LPSTR data type for
    parameters, not the LPSTR data type. The GetCommandLine function
    can be used to access Unicode strings, because it uses the LPSTR
    data type.

I suppose some of that might be correct <wink>.

More information about the Python-Dev mailing list