diff --git a/src/ChangeLog b/src/ChangeLog index e5c7a5ce8..8f9d266a7 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,5 +1,8 @@ 2002-09-03 Pavel Roskin + * help.c (interactive_display): Fallback to node "[main]" if the + requested node cannot be found. + * help.c (help_index_cmd): Eliminate unneeded search for "[Help]", which always fails. Fix crash if "[Contents]" cannot be found. Reuse more generic error message. diff --git a/src/help.c b/src/help.c index 699203624..235095c80 100644 --- a/src/help.c +++ b/src/help.c @@ -778,8 +778,13 @@ interactive_display (char *filename, char *node) if (!(main_node = search_string (data, node))) { message (1, MSG_ERROR, _(" Cannot find node %s in help file "), node); - interactive_display_finish (); - return; + + /* Fallback to [main], return if it also cannot be found */ + main_node = search_string (data, "[main]"); + if (!main_node) { + interactive_display_finish (); + return; + } } help_lines = min (LINES - 4, max (2 * LINES / 3, 18));