From: Enrico Forestieri Date: Sat, 29 Dec 2018 19:11:56 +0000 (+0100) Subject: Fix bug #4269 X-Git-Tag: 2.3.3~6 X-Git-Url: https://git.lyx.org/gitweb/?a=commitdiff_plain;h=41a8994da902031a743373c1c57d028b7c900797;p=features.git Fix bug #4269 Call gunzip with quoted filenames as they may contain spaces or other special characters. (cherry picked from commit 69726b832b4ed1859d5c9e753c4437c98f5f2966) --- diff --git a/src/support/filetools.cpp b/src/support/filetools.cpp index c91e5c4194..f2697f784b 100644 --- a/src/support/filetools.cpp +++ b/src/support/filetools.cpp @@ -925,9 +925,9 @@ FileName const unzipFile(FileName const & zipped_file, string const & unzipped_f unzippedFileName(zipped_file.toFilesystemEncoding()) : unzipped_file); // Run gunzip - string const command = "gunzip -c " + - zipped_file.toFilesystemEncoding() + " > " + - tempfile.toFilesystemEncoding(); + string const command = "gunzip -c \"" + + zipped_file.toFilesystemEncoding() + "\" > \"" + + tempfile.toFilesystemEncoding() + "\""; Systemcall one; one.startscript(Systemcall::Wait, command); // test that command was executed successfully (anon)