Bug 333637: assembleCmdLine needs to quote an empty-string argument. The
patch is contributed by Aleksey Sanin <aleksey@aleksey.com>. r=wtc git-svn-id: svn://10.0.0.236/trunk@243594 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
parent
8e4bcb3413
commit
dce7ff920b
@ -147,8 +147,11 @@ static int assembleCmdLine(char *const *argv, char **cmdLine)
|
||||
numBackslashes = 0;
|
||||
argNeedQuotes = 0;
|
||||
|
||||
/* If the argument contains white space, it needs to be quoted. */
|
||||
if (strpbrk(*arg, " \f\n\r\t\v")) {
|
||||
/*
|
||||
* If the argument is empty or contains white space, it needs to
|
||||
* be quoted.
|
||||
*/
|
||||
if (**arg == '\0' || strpbrk(*arg, " \f\n\r\t\v")) {
|
||||
argNeedQuotes = 1;
|
||||
}
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user