commit e10f389e9c63f7f2aa340dc06583bbe400a2deb1
parent ad3f47845242cb8956069291f012020b240d779a
Author: Chris Allegretta <chrisa@asty.org>
Date: Tue, 2 Oct 2001 03:54:40 +0000
Take out the unneeded case sensitive and reverse stuff from -tiny
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@813 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
Diffstat:
3 files changed, 10 insertions(+), 6 deletions(-)
diff --git a/ChangeLog b/ChangeLog
@@ -29,6 +29,7 @@ CVS code -
- Readded DISABLE_CURPOS because in certain instances (like
all the "Search Wrapper" lines) the cursor position will
be different yet we don't want the cursor position displayed.
+ - Take control-space out of -tiny build, unneeded.
- cut.c:
cut_marked_segment()
- Add magic line when cutting a selection including filebot
diff --git a/search.c b/search.c
@@ -233,7 +233,7 @@ filestruct *findnextstr(int quiet, int bracket_mode, filestruct * begin, int beg
{
filestruct *fileptr;
char *searchstr, *rev_start = NULL, *found = NULL;
- int current_x_find;
+ int current_x_find = 0;
fileptr = current;
@@ -297,7 +297,9 @@ filestruct *findnextstr(int quiet, int bracket_mode, filestruct * begin, int beg
return NULL;
}
#endif
- } else { /* reverse search */
+ }
+#ifndef NANO_SMALL
+ else { /* reverse search */
current_x_find = current_x - 1;
@@ -359,6 +361,7 @@ filestruct *findnextstr(int quiet, int bracket_mode, filestruct * begin, int beg
}
#endif
}
+#endif /* NANO_SMALL */
/* Set globals now that we are sure we found something */
current = fileptr;
diff --git a/utils.c b/utils.c
@@ -74,7 +74,6 @@ char *revstrcasestr(char *haystack, char *needle, char *rev_start)
}
return 0;
}
-#endif /* NANO_SMALL */
/* This is now mutt's version (called mutt_stristr) because it doesn't
use memory allocation to do a simple search (yuck). */
@@ -96,6 +95,7 @@ char *strcasestr(char *haystack, char *needle)
}
return NULL;
}
+#endif /* NANO_SMALL */
char *strstrwrapper(char *haystack, char *needle, char *rev_start)
{
@@ -130,22 +130,22 @@ char *strstrwrapper(char *haystack, char *needle, char *rev_start)
return 0;
}
#endif
- if (ISSET(CASE_SENSITIVE)) {
#ifndef NANO_SMALL
+ if (ISSET(CASE_SENSITIVE)) {
if (ISSET(REVERSE_SEARCH))
return revstrstr(haystack, needle, rev_start);
else
-#endif
return strstr(haystack,needle);
} else {
-#ifndef NANO_SMALL
if (ISSET(REVERSE_SEARCH))
return revstrcasestr(haystack, needle, rev_start);
else
#endif
return strcasestr(haystack, needle);
+#ifndef NANO_SMALL
}
+#endif
}
/* Thanks BG, many ppl have been asking for this... */