From 49a2448ac10e3c827d5f6d75394de7e9c8d07477 Mon Sep 17 00:00:00 2001
From: "Dr. David Alan Gilbert" <dgilbert@redhat.com>
Date: Tue, 21 Jan 2020 10:20:14 +0000
Subject: [PATCH 25/25] virtiofsd: Add printf checking to fuse_log

Use qemu's GCC_FMT_ATTR to add printf style checking to fuse_log.

Signed-off-by: Dr. David Alan Gilbert <dgilbert@redhat.com>
---
 tools/virtiofsd/fuse_log.h | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/tools/virtiofsd/fuse_log.h b/tools/virtiofsd/fuse_log.h
index 8d7091bd4d..5c2df71603 100644
--- a/tools/virtiofsd/fuse_log.h
+++ b/tools/virtiofsd/fuse_log.h
@@ -14,6 +14,7 @@
  * This file defines the logging interface of FUSE
  */
 
+#include "qemu/compiler.h"
 
 /**
  * Log severity level
@@ -68,6 +69,7 @@ void fuse_set_log_func(fuse_log_func_t func);
  * @param level severity level (FUSE_LOG_ERR, FUSE_LOG_DEBUG, etc)
  * @param fmt sprintf-style format string including newline
  */
+GCC_FMT_ATTR(2,3)
 void fuse_log(enum fuse_log_level level, const char *fmt, ...);
 
 #endif /* FUSE_LOG_H_ */
-- 
2.31.1

