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:
b888682
)
* archival/gzip.c (gzip_main): Ensure that the output is a terminal and use
author
Matt Kraai
<kraai@debian.org>
Fri, 22 Mar 2002 22:55:51 +0000
(22:55 -0000)
committer
Matt Kraai
<kraai@debian.org>
Fri, 22 Mar 2002 22:55:51 +0000
(22:55 -0000)
error_msg to display the error message.
archival/gzip.c
patch
|
blob
|
history
diff --git
a/archival/gzip.c
b/archival/gzip.c
index fed93907bdab8ea02488b7b848839e487b61cff0..44b5fe386251e981d0f4e807776b1635fdf9cbed 100644
(file)
--- a/
archival/gzip.c
+++ b/
archival/gzip.c
@@
-1312,8
+1312,8
@@
int gzip_main(int argc, char **argv)
outFileNum = STDOUT_FILENO;
}
- if (path == NULL && force == 0) {
-
p
error_msg("compressed data not written to a terminal. Use -f to force compression.");
+ if (path == NULL &&
isatty(outFileNum) &&
force == 0) {
+ error_msg("compressed data not written to a terminal. Use -f to force compression.");
free(path);
continue;
}