]> git.ipfire.org Git - thirdparty/systemd.git/blobdiff - src/locale/localed.c
build-sys: use #if Y instead of #ifdef Y everywhere
[thirdparty/systemd.git] / src / locale / localed.c
index 1cb049e74af4596e9227e3dd48c62662f49905fc..3c0c167dcfa5dfac76e96f5a445d1773f19e3f2e 100644 (file)
@@ -22,7 +22,7 @@
 #include <string.h>
 #include <unistd.h>
 
-#ifdef HAVE_XKBCOMMON
+#if HAVE_XKBCOMMON
 #include <xkbcommon/xkbcommon.h>
 #include <dlfcn.h>
 #endif
@@ -429,14 +429,17 @@ static int method_set_vc_keyboard(sd_bus_message *m, void *userdata, sd_bus_erro
         return sd_bus_reply_method_return(m, NULL);
 }
 
-#ifdef HAVE_XKBCOMMON
+#if HAVE_XKBCOMMON
 
 _printf_(3, 0)
 static void log_xkb(struct xkb_context *ctx, enum xkb_log_level lvl, const char *format, va_list args) {
         const char *fmt;
 
         fmt = strjoina("libxkbcommon: ", format);
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wformat-nonliteral"
         log_internalv(LOG_DEBUG, 0, __FILE__, __LINE__, __func__, fmt, args);
+#pragma GCC diagnostic pop
 }
 
 #define LOAD_SYMBOL(symbol, dl, name)                                   \