diff options
| author | Brad King <brad.king@kitware.com> | 2015-04-25 15:35:22 -0400 |
|---|---|---|
| committer | Brad King <brad.king@kitware.com> | 2015-04-25 15:35:22 -0400 |
| commit | e90408e91596da9fd81e77012e74bfe94b26dd83 (patch) | |
| tree | 92918899558e44f3fab15c05ae03a10eca7e0f15 /src/rustllvm/RustWrapper.cpp | |
| parent | 83263b48c39ef0e21cc9872191f4ce4877f4e05f (diff) | |
| download | rust-e90408e91596da9fd81e77012e74bfe94b26dd83.tar.gz rust-e90408e91596da9fd81e77012e74bfe94b26dd83.zip | |
std: Fix process spawn for arguments ending in backslashes on Windows
Fix `make_command_line` for the case of backslashes at the end of an argument requiring quotes. We must encode the command and arguments such that `CommandLineToArgvW` recovers them in the spawned process. Simplify the logic by using a running count of backslashes as they are encountered instead of looking ahead for quotes following them. Extend `test_make_command_line` to additionally cover: * a leading quote in an argument that requires quotes, * a backslash before a quote in an argument that requires quotes, * a backslash at the end of an argument that requires quotes, and * a backslash at the end of an argument that does not require quotes.
Diffstat (limited to 'src/rustllvm/RustWrapper.cpp')
0 files changed, 0 insertions, 0 deletions
