# HG changeset patch # User Rik # Date 1430150611 25200 # Node ID 4ff975c58584e4bd158fb23845affa2087d05c4d # Parent 4ba6c61c8794c7dc2c25f6d361ff8767b5a01f1b Check error_state before searching for help text (bug #44934). * help.cc (raw_help): Unwind multiple function calls joined by '||' operator with if tree that checks whether there was an error encountered in the previous function call. This prevents blindly continuing on after an error was encountered. diff -r 4ba6c61c8794 -r 4ff975c58584 libinterp/corefcn/help.cc --- a/libinterp/corefcn/help.cc Mon Apr 27 16:48:37 2015 +0200 +++ b/libinterp/corefcn/help.cc Mon Apr 27 09:03:31 2015 -0700 @@ -932,10 +932,21 @@ std::string w; std::string f; - (raw_help_from_symbol_table (nm, h, w, symbol_found) - || raw_help_from_file (nm, h, f, symbol_found) - || raw_help_from_map (nm, h, operators_map, symbol_found) - || raw_help_from_map (nm, h, keywords_map, symbol_found)); + bool found; + + found = raw_help_from_symbol_table (nm, h, w, symbol_found); + if (! found && ! error_state) + { + found = raw_help_from_file (nm, h, f, symbol_found); + if (! found && ! error_state) + { + found = raw_help_from_map (nm, h, operators_map, symbol_found); + if (! found && ! error_state) + { + raw_help_from_map (nm, h, keywords_map, symbol_found); + } + } + } return h; }