nano

nano with my custom patches
git clone git://bsandro.tech/nano
Log | Files | Refs | README | LICENSE

commit 9e2a12b62aaefb534d2ffed0864faaf7aed62880
parent 5be94a3bbea3b0cecb0f77bf1aba07f1eef009c5
Author: Benno Schulenberg <bensberg@telfort.nl>
Date:   Tue, 30 Oct 2018 19:05:51 +0100

tweaks: drop a check for the needle (the search string) being empty

No one ever reported seeing this.  And even if the needle were empty,
this is not a problem: it will simply match right away.

Diffstat:
Msrc/utils.c | 7-------
1 file changed, 0 insertions(+), 7 deletions(-)

diff --git a/src/utils.c b/src/utils.c @@ -266,13 +266,6 @@ bool is_separate_word(size_t position, size_t length, const char *buf) const char *strstrwrapper(const char *haystack, const char *needle, const char *start) { - if (*needle == '\0') { -#ifndef NANO_TINY - statusline(ALERT, "Searching for nothing -- please report a bug"); -#endif - return (char *)start; - } - if (ISSET(USE_REGEXP)) { if (ISSET(BACKWARDS_SEARCH)) { size_t last_find, ceiling, far_end;