Fix the build in case FIO_HAVE_DISK_UTIL is not defined
authorBart Van Assche <bvanassche@acm.org>
Mon, 6 Jan 2020 16:47:17 +0000 (08:47 -0800)
committerBart Van Assche <bvanassche@acm.org>
Mon, 6 Jan 2020 19:02:31 +0000 (11:02 -0800)
This patch fixes the following build error:

stat.c: In function 'show_thread_status_terse_all':
stat.c:1243:31: error: suggest braces around empty body in an 'if' statement [-Werror=empty-body]
   show_disk_util(1, NULL, out);
                               ^

Signed-off-by: Bart Van Assche <bvanassche@acm.org>
diskutil.h

index 15ec681a449c4a9b34929933ab95f1c85b3c1257..f6b09d22b0a4d1a91a9006900fa00bfb1019b6be 100644 (file)
@@ -120,7 +120,7 @@ static inline void print_disk_util(struct disk_util_stat *du,
                                   struct buf_output *out)
 {
 }
-#define show_disk_util(terse, parent, out)
+#define show_disk_util(terse, parent, out) do { } while (0)
 #define disk_util_prune_entries()
 #define init_disk_util(td)
 #define setup_disk_util()