projects
/
oweals
/
busybox.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
e0f5500
)
Fix segfault when testing if reaidng from stdin "-"
author
Glenn L McGrath
<bug1@ihug.co.nz>
Sun, 6 Oct 2002 23:25:23 +0000
(23:25 -0000)
committer
Glenn L McGrath
<bug1@ihug.co.nz>
Sun, 6 Oct 2002 23:25:23 +0000
(23:25 -0000)
archival/tar.c
patch
|
blob
|
history
diff --git
a/archival/tar.c
b/archival/tar.c
index 88a815de65bdd4aa63de6c7ca50b3db9ca2543fb..e6c134e3be34bad946b98248b4d01808fc95131a 100644
(file)
--- a/
archival/tar.c
+++ b/
archival/tar.c
@@
-694,7
+694,9
@@
int tar_main(int argc, char **argv)
}
}
- if (*argv[optind] == '-') {
+ /* Check if we are reading from stdin */
+ if ((argv[optind]) && (*argv[optind] == '-')) {
+ /* Default is to read from stdin, so just skip to next arg */
optind++;
}