projects
/
platform
/
upstream
/
busybox.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
14d7ea4
)
If filename is a '-' then read from stdin to stdout
author
Glenn L McGrath
<bug1@ihug.co.nz>
Mon, 30 Jul 2001 04:48:50 +0000
(
04:48
-0000)
committer
Glenn L McGrath
<bug1@ihug.co.nz>
Mon, 30 Jul 2001 04:48:50 +0000
(
04:48
-0000)
archival/gzip.c
patch
|
blob
|
history
gzip.c
patch
|
blob
|
history
diff --git
a/archival/gzip.c
b/archival/gzip.c
index
cdf2268
..
54bb727
100644
(file)
--- a/
archival/gzip.c
+++ b/
archival/gzip.c
@@
-1246,7
+1246,7
@@
int gzip_main(int argc, char **argv)
show_usage();
}
}
- if (
optind == argc
) {
+ if (
(optind == argc) || (strcmp(argv[optind], "-") == 0)
) {
fromstdin = 1;
tostdout = 1;
}
diff --git
a/gzip.c
b/gzip.c
index
cdf2268
..
54bb727
100644
(file)
--- a/
gzip.c
+++ b/
gzip.c
@@
-1246,7
+1246,7
@@
int gzip_main(int argc, char **argv)
show_usage();
}
}
- if (
optind == argc
) {
+ if (
(optind == argc) || (strcmp(argv[optind], "-") == 0)
) {
fromstdin = 1;
tostdout = 1;
}