cosmopolitan/test/libc/stdio
Justine Tunney 3f3cb0650b
Have execve() escape double quotes in cmd.exe's preferred style
This makes it possible for us to use system() and popen() with paths
that redirect to filenames that contain spaces, e.g.

    system("echo.com hello >\"hello there.txt\"")

It's difficult to solve this problem, because WIN32 only allows passing
one single argument when launching programs and each program is allowed
to tokenize that however it wants. Most software follows the convention
of cmd.exe which is poorly documented and positively byzantine.

In the future we're going to solve this by not using cmd.exe at all and
instead embedding the cocmd.com interpreter into the system() function.
In the meantime, our documentation has been updated to help recalibrate
any expectation the user might hold regarding the security of using the
Windows command interpreter.

Fixes #644
2022-10-02 09:15:46 -07:00
..
crypt_test.c Make more libc improvements 2022-08-06 17:18:40 -07:00
devrand_test.c Pay off more technical debt 2022-09-12 23:36:56 -07:00
dirstream_test.c Pay off more technical debt 2022-09-12 23:36:56 -07:00
dtoa_test.c Pay off more technical debt 2022-09-12 23:36:56 -07:00
dumphexc_test.c Pay off more technical debt 2022-09-12 23:36:56 -07:00
ecvt_test.c Pay off more technical debt 2022-09-12 23:36:56 -07:00
fgetln_test.c Pay off more technical debt 2022-09-12 23:36:56 -07:00
fgets_test.c Pay off more technical debt 2022-09-12 23:36:56 -07:00
fgetwc_test.c Fold LIBC_BITS into LIBC_INTRIN 2022-08-11 12:13:18 -07:00
fmemopen_test.c Improve memory safety 2021-10-13 17:27:13 -07:00
fputc_test.c Remove stdio lock macros from amalgamation 2022-09-10 12:03:36 -07:00
fputs_test.c Pay off more technical debt 2022-09-12 23:36:56 -07:00
freopen_test.c Fix freopen so it resets stream buffer (#61) 2021-03-07 12:12:02 -08:00
fseeko_test.c Restore zip.com and .symtab files 2022-08-21 00:17:20 -07:00
ftell_test.c Pay off more technical debt 2022-09-12 23:36:56 -07:00
fwrite_test.c Pay off more technical debt 2022-09-12 23:36:56 -07:00
getdelim_test.c Clean up some code 2022-08-20 12:32:51 -07:00
getrandom_test.c Fold LIBC_RAND into LIBC_STDIO/TINYMATH/INTRIN 2022-08-11 12:32:00 -07:00
gz_test.c Add zlib gzip functions 2022-05-12 12:17:40 -07:00
iconv_test.c Pay off more technical debt 2022-09-12 23:36:56 -07:00
joinstrlist_test.c Pay off more technical debt 2022-09-12 23:36:56 -07:00
memory_test.c Pay off more technical debt 2022-09-12 23:36:56 -07:00
mkostempsm_test.c Fold LIBC_BITS into LIBC_INTRIN 2022-08-11 12:13:18 -07:00
mt19937_test.c Pay off more technical debt 2022-09-12 23:36:56 -07:00
rand_test.c Fold LIBC_RAND into LIBC_STDIO/TINYMATH/INTRIN 2022-08-11 12:32:00 -07:00
rngset_test.c Fold LIBC_RAND into LIBC_STDIO/TINYMATH/INTRIN 2022-08-11 12:32:00 -07:00
spawn_test.c Clean up some code 2022-08-20 12:32:51 -07:00
system_test.c Have execve() escape double quotes in cmd.exe's preferred style 2022-10-02 09:15:46 -07:00
test.mk Have execve() escape double quotes in cmd.exe's preferred style 2022-10-02 09:15:46 -07:00
tmpfile_test.c Pay off more technical debt 2022-09-12 23:36:56 -07:00
ungetc_test.c Unbloat the build 2022-08-11 00:15:29 -07:00
vappendf_test.c Pay off more technical debt 2022-09-12 23:36:56 -07:00