From: Jens Axboe Date: Mon, 14 Apr 2014 14:57:35 +0000 (-0600) Subject: stat: fix wrong check for whether we have a description or not X-Git-Tag: fio-2.1.9~54 X-Git-Url: https://git.kernel.dk/?p=fio.git;a=commitdiff_plain;h=0a3c52f0875c85b6750239a8b65bfe230d28df35 stat: fix wrong check for whether we have a description or not It's an array, hence never NULL. Check for size instead. Signed-off-by: Jens Axboe --- diff --git a/stat.c b/stat.c index 5a553d00..ca733108 100644 --- a/stat.c +++ b/stat.c @@ -831,7 +831,7 @@ static void show_thread_status_terse_v2(struct thread_stat *ts, log_info("\n"); /* Additional output if description is set */ - if (ts->description) + if (strlen(ts->description)) log_info(";%s", ts->description); log_info("\n");