ENH: Fix argument parsing on UNIX with spaces
This commit is contained in:
parent
2c33b3db65
commit
d86d2fdf12
|
@ -349,10 +349,22 @@ bool cmSystemTools::RunSingleCommand(
|
|||
{
|
||||
// Parse an unquoted argument.
|
||||
while(*c && *c != ' ' && *c != '\t')
|
||||
{
|
||||
if(*c == '\\')
|
||||
{
|
||||
++c;
|
||||
if(*c)
|
||||
{
|
||||
arg.append(1, *c);
|
||||
++c;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
arg.append(1, *c);
|
||||
++c;
|
||||
}
|
||||
}
|
||||
args.push_back(arg);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue