grep: fix ARGC()

This commit is contained in:
Connor Lane Smith 2012-06-09 18:49:02 +01:00
parent c2c5ea9c60
commit c68bba6867

3
grep.c
View File

@ -21,7 +21,6 @@ static char mode = 0;
int int
main(int argc, char *argv[]) main(int argc, char *argv[])
{ {
char c;
int i, n, flags = REG_NOSUB; int i, n, flags = REG_NOSUB;
regex_t preg; regex_t preg;
FILE *fp; FILE *fp;
@ -34,7 +33,7 @@ main(int argc, char *argv[])
case 'l': case 'l':
case 'n': case 'n':
case 'q': case 'q':
mode = c; mode = ARGC();
break; break;
case 'i': case 'i':
flags |= REG_ICASE; flags |= REG_ICASE;