From: John Beppu Date: Wed, 14 Jun 2000 00:19:14 +0000 (-0000) Subject: + removed some cruft left over from when lines could be too long. X-Git-Tag: 0_45~50 X-Git-Url: https://git.librecmc.org/?a=commitdiff_plain;h=d84990eb1ffe7eac68eb9006969bf530f297b078;p=oweals%2Fbusybox.git + removed some cruft left over from when lines could be too long. --- diff --git a/findutils/grep.c b/findutils/grep.c index 1272a464b..e29606405 100644 --- a/findutils/grep.c +++ b/findutils/grep.c @@ -66,15 +66,12 @@ static int match = FALSE, beQuiet = FALSE; static void do_grep(FILE * fp, char *needle, char *fileName, int tellName, int ignoreCase, int tellLine, int invertSearch) { - char *cp; long line = 0; char *haystack; int truth = !invertSearch; while ((haystack = cstring_lineFromFile(fp))) { line++; - cp = &haystack[strlen(haystack) - 1]; - if (find_match(haystack, needle, ignoreCase) == truth) { if (tellName == TRUE) printf("%s:", fileName); diff --git a/grep.c b/grep.c index 1272a464b..e29606405 100644 --- a/grep.c +++ b/grep.c @@ -66,15 +66,12 @@ static int match = FALSE, beQuiet = FALSE; static void do_grep(FILE * fp, char *needle, char *fileName, int tellName, int ignoreCase, int tellLine, int invertSearch) { - char *cp; long line = 0; char *haystack; int truth = !invertSearch; while ((haystack = cstring_lineFromFile(fp))) { line++; - cp = &haystack[strlen(haystack) - 1]; - if (find_match(haystack, needle, ignoreCase) == truth) { if (tellName == TRUE) printf("%s:", fileName);