# HG changeset patch # User Philip Nienhuis # Date 1425669133 -3600 # Fri Mar 06 20:12:13 2015 +0100 # Node ID f0ce1faa737a6f6c50b708c75ba440ca9ed7365b # Parent 5c6e73488550a5cf92cbef416a96c8723e263976 html_help_text.m: do not blindly assume presence of 'charset' in texinfo diff -r 5c6e73488550 -r f0ce1faa737a inst/html_help_text.m --- a/inst/html_help_text.m Sat Feb 28 17:58:16 2015 +0100 +++ b/inst/html_help_text.m Fri Mar 06 20:12:13 2015 +0100 @@ -88,10 +88,12 @@ ## Check encoding tmp = regexp (text, "charset\s*=\s*([^\s\"]*)", "tokens"); - charset = tmp{1}{1}; - if (! strcmp (options.charset, charset)) - warning (["makeinfo's output is encoded in %s, but will be " ... - "interpreted with options.charset = %s"], charset, options.charset); + if (! isempty (tmp)) + charset = tmp{1}{1}; + if (! strcmp (options.charset, charset)) + warning (["makeinfo's output is encoded in %s, but will be " ... + "interpreted with options.charset = %s"], charset, options.charset); + endif endif ## Extract the body of makeinfo's output