summaryrefslogtreecommitdiff
path: root/src/shared/macro.h
diff options
context:
space:
mode:
authorLennart Poettering <lennart@poettering.net>2014-02-20 18:18:32 +0100
committerLennart Poettering <lennart@poettering.net>2014-02-20 18:18:32 +0100
commitbcfce235a3d757f0ec3b0c01e8583382db1adfe2 (patch)
tree78a0c2102a7b0db526c01abeb352e77e708f418e /src/shared/macro.h
parentbeb999379ced9e8d765e533e43d35aab11aa5c39 (diff)
macro: introduce a nice macro for disabling -Wformat-nonliteral temporarily
Diffstat (limited to 'src/shared/macro.h')
-rw-r--r--src/shared/macro.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/shared/macro.h b/src/shared/macro.h
index 959a9f7fb1..1941f0e651 100644
--- a/src/shared/macro.h
+++ b/src/shared/macro.h
@@ -51,6 +51,10 @@
_Pragma("GCC diagnostic push"); \
_Pragma("GCC diagnostic ignored \"-Wdeclaration-after-statement\"")
+#define DISABLE_WARNING_FORMAT_NONLITERAL \
+ _Pragma("GCC diagnostic push"); \
+ _Pragma("GCC diagnostic ignored \"-Wformat-nonliteral\"")
+
#define REENABLE_WARNING \
_Pragma("GCC diagnostic pop")