Broken quote handling when spawning a process from a cmd script. #91991
Labels
C-bug
Category: This is a bug.
O-windows
Operating system: Windows
P-high
High priority
regression-from-stable-to-nightly
Performance or correctness regression from stable to nightly.
T-libs
Relevant to the library team, which will review and decide on the PR/issue.
Code
I tried this code:
I expected to see this happen:
Instead, this happened:
This is caused by different quote handling.
The first (correct) command line for the spawned process (as observed by
procmon
) is:The broken one is:
The command for
cmd
must be in additional set of quotes, as the first and last one are stripped.It works when there are no spaces in the arguments due to the exception rule, see https://docs.microsoft.com/en-us/windows-server/administration/windows-commands/cmd#remarks
Version it worked on
Stable. It worked up until nightly-2021-11-20
Version with regression
nightly-2021-11-21
@rustbot modify labels: +regression-from-stable-to-nightly -regression-untriaged
The text was updated successfully, but these errors were encountered: