aboutsummaryrefslogtreecommitdiff
path: root/src/utils.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/utils.c')
-rw-r--r--src/utils.c2
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;