aboutsummaryrefslogtreecommitdiff
path: root/src/thread-pool.c
diff options
context:
space:
mode:
authorThomas White <taw@bitwiz.org.uk>2010-10-10 16:31:08 +0200
committerThomas White <taw@physics.org>2012-02-22 15:27:02 +0100
commita9adbc73158e8f8b225cd59d62ad5ade648c8241 (patch)
tree41fefc339f97b9fa1c3b1f80b266e93ca00fb671 /src/thread-pool.c
parentf4c16e7eb16256b568c99f01962bb8fed0a1bb1a (diff)
Don't draw progress bar unless requested
Diffstat (limited to 'src/thread-pool.c')
-rw-r--r--src/thread-pool.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/thread-pool.c b/src/thread-pool.c
index b27c0441..ac508b11 100644
--- a/src/thread-pool.c
+++ b/src/thread-pool.c
@@ -78,7 +78,9 @@ static void *worker_thread(void *pargsv)
pthread_mutex_lock(&q->lock);
q->status[mytask] = TASK_FINISHED;
q->n_done++;
- progress_bar(q->n_done, q->n_tasks, q->text);
+ if ( q->text != NULL ) {
+ progress_bar(q->n_done, q->n_tasks, q->text);
+ }
pthread_mutex_unlock(&q->lock);
} while ( 1 );