From: Benno Schulenberg Date: Fri, 6 Nov 2015 20:25:05 +0000 (+0000) Subject: Not checking whether a function has a help line; it's irrelevant. X-Git-Tag: v2.5.0~70 X-Git-Url: https://git.wh0rd.org/?a=commitdiff_plain;h=53fbcf77f29d5cae3298330402f94d832af27506;p=nano.git Not checking whether a function has a help line; it's irrelevant. git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@5392 35c25a1d-7b9e-4130-9fde-d3aeb78583b8 --- diff --git a/ChangeLog b/ChangeLog index 08d21b2f..9c088a46 100644 --- a/ChangeLog +++ b/ChangeLog @@ -2,6 +2,9 @@ * src/files.c (write_lockfile): Don't bail out when the hostname is overlong, but instead truncate it properly and continue. This fixes Ubuntu bug #1509081 reported by Sam Reed. + * src/global.c (length_of_list), src/winio.c(get_mouseinput): Don't + check whether a function has a help line, since all of them have. + (And even if some didn't, they would still be valid functions.) 2015-11-02 Benno Schulenberg * src/nano.h: Delete an unused type definition. diff --git a/src/global.c b/src/global.c index 0f6b646b..0c7b63fe 100644 --- a/src/global.c +++ b/src/global.c @@ -217,11 +217,7 @@ size_t length_of_list(int menu) size_t i = 0; for (f = allfuncs; f != NULL; f = f->next) - if ((f->menus & menu) != 0 -#ifndef DISABLE_HELP - && strlen(f->help) > 0 -#endif - ) { + if ((f->menus & menu) != 0) { i++; } return i; diff --git a/src/winio.c b/src/winio.c index b3a9da2e..53025405 100644 --- a/src/winio.c +++ b/src/winio.c @@ -1684,10 +1684,6 @@ int get_mouseinput(int *mouse_x, int *mouse_y, bool allow_shortcuts) for (f = allfuncs; f != NULL; f = f->next) { if ((f->menus & currmenu) == 0) continue; -#ifndef DISABLE_HELP - if (!f->help || strlen(f->help) == 0) - continue; -#endif if (first_sc_for(currmenu, f->scfunc) == NULL) continue; /* Tick off an actually shown shortcut. */