summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/util/RuntimeError.hxx10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/util/RuntimeError.hxx b/src/util/RuntimeError.hxx
index 3d523013b..962bad67b 100644
--- a/src/util/RuntimeError.hxx
+++ b/src/util/RuntimeError.hxx
@@ -35,6 +35,12 @@
#include <stdio.h>
+#ifdef __clang__
+#pragma GCC diagnostic push
+// TODO: fix this warning properly
+#pragma GCC diagnostic ignored "-Wformat-security"
+#endif
+
template<typename... Args>
static inline std::runtime_error
FormatRuntimeError(const char *fmt, Args&&... args) noexcept
@@ -53,4 +59,8 @@ FormatInvalidArgument(const char *fmt, Args&&... args) noexcept
return std::invalid_argument(buffer);
}
+#ifdef __clang__
+#pragma GCC diagnostic pop
+#endif
+
#endif