Windows wide path conversions: don't use SYSPATH outside pathut.cpp

This commit is contained in:
Jean-Francois Dockes
2020-09-30 12:31:51 +01:00
parent a15b2d5f45
commit e8a5ee327d
4 changed files with 51 additions and 13 deletions
+2 -2
View File
@@ -793,9 +793,9 @@ int ExecCmd::startExec(const string &cmd, const vector<string>& args,
int flags = CREATE_NEW_PROCESS_GROUP | CREATE_UNICODE_ENVIRONMENT;
// Create the child process.
LOGDEB("ExecCmd:startExec: cmdline [" << cmdline << "]\n");
SYSPATH(cmdline, wcmdline);
auto wcmdline = utf8towchar(cmdline);
bSuccess = CreateProcessW(NULL, // app name
wcmdline, // command line
wcmdline.get(), // command line
NULL, // process security attributes
NULL, // primary thread security attrs
TRUE, // handles are inherited