From 7098dd0cd03170f08b7c525184169d4b2237f325 Mon Sep 17 00:00:00 2001 From: Benno Schulenberg Date: Thu, 17 Mar 2016 18:51:46 +0000 Subject: [PATCH] Pruning two #ifdefs, like elsewhere, to reduce the clutter. git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@5740 35c25a1d-7b9e-4130-9fde-d3aeb78583b8 --- ChangeLog | 1 + src/search.c | 12 +++++------- 2 files changed, 6 insertions(+), 7 deletions(-) diff --git a/ChangeLog b/ChangeLog index a5781802..a646bb33 100644 --- a/ChangeLog +++ b/ChangeLog @@ -2,6 +2,7 @@ * src/search.c (do_research): Use the Search key bindings also during a Re-search, to enable cancelling. This fixes Savannah bug #47159. * src/search.c (do_replace): Remove two redundant returns. + * src/search.c (findnextstr): Prune two #ifdefs. 2016-03-14 Benno Schulenberg * src/color.c (color_update): Don't dereference a possible NULL. diff --git a/src/search.c b/src/search.c index dd85fe44..f6476700 100644 --- a/src/search.c +++ b/src/search.c @@ -340,13 +340,12 @@ bool findnextstr( if (ISSET(BACKWARDS_SEARCH)) { fileptr = fileptr->prev; current_y_find--; - } else { + } else #endif + { fileptr = fileptr->next; current_y_find++; -#ifndef NANO_TINY } -#endif if (fileptr == NULL) { /* We've reached the start or end of the buffer, so wrap around. */ @@ -354,13 +353,12 @@ bool findnextstr( if (ISSET(BACKWARDS_SEARCH)) { fileptr = openfile->filebot; current_y_find = editwinrows - 1; - } else { + } else #endif + { fileptr = openfile->fileage; current_y_find = 0; -#ifndef NANO_TINY } -#endif statusbar(_("Search Wrapped")); } @@ -490,7 +488,7 @@ void do_findnext(void) } else do_research(); } -#endif +#endif /* !NANO_TINY */ #if !defined(NANO_TINY) || !defined(DISABLE_BROWSER) /* Search for the last string without prompting. */