Cleanup: quiet GCC's -Wsuggest-attribute=format warning

This commit is contained in:
Campbell Barton
2023-08-17 16:51:59 +10:00
parent bbe4f6cf74
commit 0a04a6d1a1
2 changed files with 6 additions and 0 deletions

View File

@@ -786,6 +786,7 @@ macro(remove_strict_flags)
if(CMAKE_COMPILER_IS_GNUCC)
remove_cc_flag(
"-Wstrict-prototypes"
"-Wsuggest-attribute=format"
"-Wmissing-prototypes"
"-Wmissing-declarations"
"-Wmissing-format-attribute"

View File

@@ -1392,6 +1392,11 @@ static void ghost_wl_display_report_error(wl_display *display)
::exit(-1);
}
#ifdef __GNUC__
static void ghost_wayland_log_handler(const char *msg, va_list arg)
__attribute__((format(printf, 1, 0)));
#endif
/**
* Callback for WAYLAND to run when there is an error.
*