From a27900e3ffdae707c326a8fd5789e8af0f0c7b0b Mon Sep 17 00:00:00 2001 From: Scott Kostyshak Date: Sat, 12 Jan 2013 16:00:52 -0500 Subject: [PATCH] LyXRC: escape existing quote characters in 'cmd' (cherry picked from commit a4a836916b1257b215546b2b7886e009df5876a9) --- src/LyXRC.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/LyXRC.cpp b/src/LyXRC.cpp index 2a1e0168b4..c59cb8ef84 100644 --- a/src/LyXRC.cpp +++ b/src/LyXRC.cpp @@ -2785,7 +2785,7 @@ void LyXRC::write(ostream & os, bool ignore_system_lyxrc, string const & name) c || sysfmt == sysend // format not found || sysfmt->second.count(cmd) == 0 // this command not found ) - os << "\\viewer_alternatives " << fmt << " \"" << cmd << "\"\n"; + os << "\\viewer_alternatives " << fmt << " \"" << escapeCommand(cmd) << "\"\n"; } } if (tag != RC_LAST) @@ -2810,7 +2810,7 @@ void LyXRC::write(ostream & os, bool ignore_system_lyxrc, string const & name) c || sysfmt == sysend // format not found || sysfmt->second.count(cmd) == 0 // this command not found ) - os << "\\editor_alternatives " << fmt << " \"" << cmd << "\"\n"; + os << "\\editor_alternatives " << fmt << " \"" << escapeCommand(cmd) << "\"\n"; } } if (tag != RC_LAST) -- 2.39.5