Document execve() limitation on Windows

Closes #1253
This commit is contained in:
Justine Tunney 2024-12-24 12:20:48 -08:00
parent 0158579493
commit cc8a9eb93c
No known key found for this signature in database
GPG key ID: BE714B4575D6E328

View file

@ -57,6 +57,11 @@
* compiled by MSVC or Cygwin is launched instead, then only the stdio
* file descriptors can be passed along.
*
* On Windows, the parent process must be a cosmo program. If you're
* calling execve() from a program that wasn't launched by cosmopolitan
* bash, or some similar program, then ask yourself if what you really
* want is to either (a) call fork() first, or (b) use posix_spawn().
*
* On Windows, `argv` and `envp` can't contain binary strings. They need
* to be valid UTF-8 in order to round-trip the WIN32 API, without being
* corrupted.