"A little patch for the strings applet of the busybox development tree

that substitutes two lines of code with a libbb function saving a couple
of bytes." - Tito
This commit is contained in:
Glenn L McGrath 2003-08-29 15:48:37 +00:00
parent 21aacba2b7
commit e01c550eab

View File

@ -82,8 +82,7 @@ int strings_main(int argc, char **argv)
pipe: pipe:
count=0; count=0;
do do{
{
c=fgetc(file); c=fgetc(file);
if(ISSTR(c)) if(ISSTR(c))
{ {
@ -110,11 +109,9 @@ pipe:
i=0; i=0;
} }
count++; count++;
} }while(c!=EOF);
while(c!=EOF);
if(file!=stdin) bb_fclose_nonstdin(file);
fclose(file);
} }
else else
{ {