tools: suppress GLib warnings when gst-inspecting deprecated properties
authorTim-Philipp Müller <tim@centricular.com>
Fri, 4 Jul 2014 18:40:28 +0000 (19:40 +0100)
committerTim-Philipp Müller <tim@centricular.com>
Fri, 4 Jul 2014 18:40:28 +0000 (19:40 +0100)
GLib in git will spew a g_warning() when a property marked as
deprecated via param spec flags is accessed. Suppress this by
setting the appropriate environment variable.

tools/gst-inspect.c

index 992f4ff..f97eb2a 100644 (file)
@@ -1484,6 +1484,9 @@ main (int argc, char *argv[])
   textdomain (GETTEXT_PACKAGE);
 #endif
 
+  /* avoid glib warnings when inspecting deprecated properties */
+  g_setenv ("G_ENABLE_DIAGNOSTIC", "0", FALSE);
+
   g_set_prgname ("gst-inspect-" GST_API_VERSION);
 
 #ifndef GST_DISABLE_OPTION_PARSING