diff options
Diffstat (limited to 'src/utils.c')
-rw-r--r-- | src/utils.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/utils.c b/src/utils.c index 196cda3f..99a2dd75 100644 --- a/src/utils.c +++ b/src/utils.c @@ -60,6 +60,8 @@ void progress_bar(int val, int total, const char *text) char s[1024]; const int width = 50; + if ( total == 0 ) return; + if ( !isatty(STDERR_FILENO) ) return; if ( tcgetpgrp(STDERR_FILENO) != getpgrp() ) return; |