changeset 27642:2f4213af7067

handle quoted file names in gl2ps auxiliary command strings (bug #57174) * gl2ps-print.cc (gl2ps_renderer::draw): Fix command file name extraction to handle double- or single-quoted file names.
author Mike Miller <mtmiller@octave.org>
date Tue, 05 Nov 2019 12:09:52 -0800
parents ab13485346c2
children 337132e66ec2
files libinterp/corefcn/gl2ps-print.cc
diffstat 1 files changed, 2 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/libinterp/corefcn/gl2ps-print.cc	Tue Nov 05 00:09:56 2019 -0500
+++ b/libinterp/corefcn/gl2ps-print.cc	Tue Nov 05 12:09:52 2019 -0800
@@ -403,11 +403,11 @@
             else
               include_graph = old_print_cmd;
 
-            size_t n_begin = include_graph.find_first_not_of (' ');
+            size_t n_begin = include_graph.find_first_not_of (" \"'");
 
             if (n_begin != std::string::npos)
               {
-                size_t n_end = include_graph.find_last_not_of (' ');
+                size_t n_end = include_graph.find_last_not_of (" \"'");
                 include_graph = include_graph.substr (n_begin,
                                                       n_end - n_begin + 1);
               }