File tree 1 file changed +3
-1
lines changed
1 file changed +3
-1
lines changed Original file line number Diff line number Diff line change 36
36
% files when appending (Javier Paredes); sanity check of inputs
37
37
% 24/01/18: Fixed error in case of existing output file (append mode)
38
38
% 24/01/18: Fixed issue #213: non-ASCII characters in folder names on Windows
39
+ % 06/12/18: Avoid an "invalid escape-char" warning upon error
39
40
40
41
function append_pdfs(varargin )
41
42
@@ -75,7 +76,7 @@ function append_pdfs(varargin)
75
76
[status , errMsg ] = ghostscript([' @"' cmdfile ' "' ]);
76
77
77
78
% Check for ghostscript execution errors
78
- if status && ~isempty(strfind(errMsg ,' undefinedfile' )) && ispc
79
+ if status && ~isempty(strfind(errMsg ,' undefinedfile' )) && ispc % #ok<STREMP>
79
80
% Fix issue #213: non-ASCII characters in folder names on Windows
80
81
for fileIdx = 2 : numel(varargin )
81
82
[fpath ,fname ,fext ] = fileparts(varargin{fileIdx });
@@ -91,6 +92,7 @@ function append_pdfs(varargin)
91
92
92
93
% Check for ghostscript execution errors
93
94
if status
95
+ errMsg = strrep(errMsg ,' \' ,' \\ ' ); % Avoid an "invalid escape-char" warning
94
96
error(' YMA:export_fig:append_pdf' ,errMsg );
95
97
end
96
98
You can’t perform that action at this time.
0 commit comments