check: fix werror build with clang
authorMatthew Waters <matthew@centricular.com>
Mon, 26 Aug 2019 12:36:25 +0000 (22:36 +1000)
committerMatthew Waters <matthew@centricular.com>
Mon, 26 Aug 2019 12:42:37 +0000 (12:42 +0000)
Silence -Wformat-nonliteral warnings from the internal copy of libcheck

../subprojects/gstreamer/libs/gst/check/libcheck/check.c:379:29: warning: format string is not a string literal [-Wformat-nonliteral]
    vsnprintf (buf, BUFSIZ, msg, ap);
                            ^~~
../subprojects/gstreamer/libs/gst/check/libcheck/check_error.c:48:21: warning: format string is not a string literal [-Wformat-nonliteral]
  vfprintf (stderr, fmt, args);
                    ^~~
../subprojects/gstreamer/libs/gst/check/libcheck/check_str.c:92:29: warning: format string is not a string literal [-Wformat-nonliteral]
    n = vsnprintf (p, size, fmt, ap);
                            ^~~

libs/gst/check/libcheck/meson.build

index 17d3f01..4e6b1e3 100644 (file)
@@ -72,7 +72,8 @@ foreach arg : [
   '-Wno-missing-prototypes',
   '-Wno-missing-declarations',
   '-Wno-old-style-definition',
-  '-Wno-declaration-after-statement']
+  '-Wno-declaration-after-statement',
+  '-Wno-format-nonliteral']
   if cc.has_argument(arg)
     no_warn_args += [arg]
   endif