aboutsummaryrefslogtreecommitdiff
path: root/archival/tar.c
diff options
context:
space:
mode:
Diffstat (limited to 'archival/tar.c')
-rw-r--r--archival/tar.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/archival/tar.c b/archival/tar.c
index 6f18dc43f..3227ce5bd 100644
--- a/archival/tar.c
+++ b/archival/tar.c
@@ -167,7 +167,7 @@ extern int tar_main(int argc, char **argv)
tarName = *(++argv);
if (tarName == NULL)
fatalError( "Option requires an argument: No file specified\n");
- if (!strcmp(tarName, "-"))
+ if (!strcmp(tarName, "-") && createFlag == TRUE)
tostdoutFlag = TRUE;
stopIt=TRUE;
break;