Reducing the scope of a variable.

git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@5359 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
master
Benno Schulenberg 2015-08-16 08:49:29 +00:00
parent a9aa0ef997
commit 5440796f31
2 changed files with 3 additions and 2 deletions

View File

@ -1,6 +1,7 @@
2015-08-16 Benno Schulenberg <bensberg@justemail.net>
* src/help.c (help_init, help_line_len): Avoid wide paragraphs of text
in the help screens: wrap them at 74 columns if the screen is wider.
* src/help.c (help_init): Reduce the scope of a variable.
2015-08-13 Benno Schulenberg <bensberg@justemail.net>
* src/search.c (do_find_bracket): Remove mistaken comparison between

View File

@ -198,7 +198,6 @@ void help_init(void)
char *ptr;
const subnfunc *f;
const sc *s;
int scsfound = 0;
#ifndef NANO_TINY
bool old_whitespace = ISSET(WHITESPACE_DISPLAY);
@ -408,12 +407,13 @@ void help_init(void)
/* Now add our shortcut info. */
for (f = allfuncs; f != NULL; f = f->next) {
int scsfound = 0;
if ((f->menus & currmenu) == 0)
continue;
/* Let's simply show the first two shortcuts from the list. */
for (s = sclist, scsfound = 0; s != NULL; s = s->next) {
for (s = sclist; s != NULL; s = s->next) {
if ((s->menus & currmenu) == 0)
continue;