make quoted filenames work when " is active

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@10095 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
Georg Baum 2005-06-21 09:01:41 +00:00
parent 1a8b8902c0
commit ddedf9f5ef
2 changed files with 8 additions and 1 deletions

View File

@ -1,3 +1,8 @@
2005-06-21 Georg Baum <Georg.Baum@post.rwth-aachen.de>
* filetools.C (latex_path): protect " with \string since it may be
active
2005-05-07 Rob Bearman <robbear@hyperfine.com>
* fs_extras.C (copy_file): noclobber and CopyFile's bFailIfExists

View File

@ -87,7 +87,9 @@ string const latex_path(string const & original_path)
string path = subst(original_path, "\\", "/");
path = subst(path, "~", "\\string~");
if (path.find(' ') != string::npos)
path = '"' + path + '"';
// We can't use '"' because " is sometimes active (e.g. if
// babel is loaded with the "german" option)
path = "\\string\"" + path + "\\string\"";
return path;
}