Fix bug #9342: LaTeX build get stuck for unconventional path name

The reason being that the TEXINPUTS path list was not quoted on Windows.
This was no problem with spaces but some special characters are
interpreted by the shell and can cause problems. In this particular
case, the '&' character was being interpreted as a command separator.
This commit is contained in:
Enrico Forestieri 2014-11-27 21:59:09 +01:00
parent 38f8858671
commit 11b7b7234e

View File

@ -703,8 +703,15 @@ string latexEnvCmdPrefix(string const & path)
return "env TEXINPUTS=\"." + sep + texinputs_prefix
+ sep + texinputs + "\" ";
else
return "cmd /d /c set TEXINPUTS=." + sep + texinputs_prefix
+ sep + texinputs + "&";
#ifndef USE_QPROCESS
return "cmd /d /c set \"TEXINPUTS=."
+ sep + texinputs_prefix
+ sep + texinputs + "\"&";
#else
return "cmd /d /c set \"\"\"TEXINPUTS=."
+ sep + texinputs_prefix
+ sep + texinputs + "\"\"\"&";
#endif
}