mirror of
https://github.com/sheumann/hush.git
synced 2025-02-28 20:31:33 +00:00
Make output the same as upstream, patch by Tito
This commit is contained in:
parent
a69fd2ecf6
commit
dd3461af2f
@ -50,7 +50,7 @@ int strings_main(int argc, char **argv)
|
|||||||
minlen = -1;
|
minlen = -1;
|
||||||
while ((ch = getopt(argc, argv, "an:of")) > 0)
|
while ((ch = getopt(argc, argv, "an:of")) > 0)
|
||||||
switch(ch) {
|
switch(ch) {
|
||||||
case '-':
|
case 'a':
|
||||||
break;
|
break;
|
||||||
case 'f':
|
case 'f':
|
||||||
fflg = 1;
|
fflg = 1;
|
||||||
@ -86,6 +86,7 @@ int strings_main(int argc, char **argv)
|
|||||||
foff = 0;
|
foff = 0;
|
||||||
|
|
||||||
for (cnt = 0; (ch = getchar()) != EOF;) {
|
for (cnt = 0; (ch = getchar()) != EOF;) {
|
||||||
|
foff++;
|
||||||
if (ISSTR(ch)) {
|
if (ISSTR(ch)) {
|
||||||
if (!cnt)
|
if (!cnt)
|
||||||
C = bfr;
|
C = bfr;
|
||||||
@ -95,7 +96,7 @@ int strings_main(int argc, char **argv)
|
|||||||
if (fflg)
|
if (fflg)
|
||||||
printf("%s:", file);
|
printf("%s:", file);
|
||||||
if (oflg)
|
if (oflg)
|
||||||
printf("%07ld %s", (long)(foff - minlen), (char *)bfr);
|
printf("%7ld %s", (long)(foff - minlen), (char *)bfr);
|
||||||
else
|
else
|
||||||
printf("%s", bfr);
|
printf("%s", bfr);
|
||||||
while ((ch = getchar()) != EOF && ISSTR(ch))
|
while ((ch = getchar()) != EOF && ISSTR(ch))
|
||||||
|
Loading…
x
Reference in New Issue
Block a user