mirror of
https://github.com/sheumann/hush.git
synced 2024-11-05 06:07:00 +00:00
Fix segfault when testing if reaidng from stdin "-"
This commit is contained in:
parent
e0f5500bb5
commit
2983330512
@ -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++;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user