tools, tests: g_thread_init() is deprecated in glib master
authorTim-Philipp Müller <tim.muller@collabora.co.uk>
Sun, 4 Dec 2011 17:02:39 +0000 (17:02 +0000)
committerTim-Philipp Müller <tim.muller@collabora.co.uk>
Sun, 4 Dec 2011 17:16:36 +0000 (17:16 +0000)
It's not needed any longer.

tests/examples/encoding/encoding.c
tests/examples/overlay/gtk-xoverlay.c
tests/examples/overlay/qt-xoverlay.cpp
tests/examples/seek/jsseek.c
tests/examples/seek/scrubby.c
tests/examples/seek/seek.c
tests/icles/stress-playbin.c
tests/icles/test-colorkey.c
tests/icles/test-xoverlay.c
tools/gst-discoverer.c

index 86d7f8f..4c4865c 100644 (file)
@@ -395,8 +395,10 @@ main (int argc, char **argv)
   GstEncodingProfile *prof;
   gchar *inputuri;
 
+#if !GLIB_CHECK_VERSION (2, 31, 0)
   if (!g_thread_supported ())
     g_thread_init (NULL);
+#endif
 
   ctx = g_option_context_new ("- encode URIs with GstProfile and encodebin");
   g_option_context_add_main_entries (ctx, options, NULL);
index c05685c..3050bd7 100644 (file)
@@ -98,8 +98,10 @@ main (int argc, char **argv)
   gulong embed_xid;
   GstStateChangeReturn sret;
 
+#if !GLIB_CHECK_VERSION (2, 31, 0)
   if (!g_thread_supported ())
     g_thread_init (NULL);
+#endif
 
   gst_init (&argc, &argv);
   gtk_init (&argc, &argv);
index aa483a7..cf8840f 100644 (file)
@@ -80,8 +80,10 @@ find_video_sink (void)
 
 int main(int argc, char *argv[])
 {
+#if !GLIB_CHECK_VERSION (2, 31, 0)
   if (!g_thread_supported ())
     g_thread_init (NULL);
+#endif
 
   gst_init (&argc, &argv);
   QApplication app(argc, argv);
index ab2bfc3..fd16c54 100644 (file)
@@ -2672,8 +2672,10 @@ main (int argc, char **argv)
   GOptionContext *ctx;
   GError *err = NULL;
 
+#if !GLIB_CHECK_VERSION (2, 31, 0)
   if (!g_thread_supported ())
     g_thread_init (NULL);
+#endif
 
   ctx = g_option_context_new ("- test seeking in gsteamer");
   g_option_context_add_main_entries (ctx, options, NULL);
index c9a02f4..501d559 100644 (file)
@@ -463,8 +463,10 @@ main (int argc, char **argv)
   GOptionContext *ctx;
   GError *err = NULL;
 
+#if !GLIB_CHECK_VERSION (2, 31, 0)
   if (!g_thread_supported ())
     g_thread_init (NULL);
+#endif
 
   ctx = g_option_context_new ("seek");
   g_option_context_add_main_entries (ctx, options, NULL);
index b04967b..60c0997 100644 (file)
@@ -2675,8 +2675,10 @@ main (int argc, char **argv)
   GOptionContext *ctx;
   GError *err = NULL;
 
+#if !GLIB_CHECK_VERSION (2, 31, 0)
   if (!g_thread_supported ())
     g_thread_init (NULL);
+#endif
 
   ctx = g_option_context_new ("- test seeking in gsteamer");
   g_option_context_add_main_entries (ctx, options, NULL);
index 3b90710..30970ce 100644 (file)
@@ -100,8 +100,10 @@ main (int argc, char **argv)
   };
   GTimer *timer;
 
+#if !GLIB_CHECK_VERSION (2, 31, 0)
   if (!g_thread_supported ())
     g_thread_init (NULL);
+#endif
 
   ctx = g_option_context_new ("FILES OR DIRECTORIES WITH AUDIO FILES");
   g_option_context_add_main_entries (ctx, options, NULL);
index ac04ba5..9d88aec 100644 (file)
@@ -172,8 +172,10 @@ main (int argc, char **argv)
   GstPropertyProbe *probe;
   GValueArray *arr;
 
+#if !GLIB_CHECK_VERSION (2, 31, 0)
   if (!g_thread_supported ())
     g_thread_init (NULL);
+#endif
 
   gst_init (&argc, &argv);
   gtk_init (&argc, &argv);
index 9ef552e..c1610b6 100644 (file)
@@ -144,8 +144,10 @@ main (gint argc, gchar ** argv)
   gulong embed_xid = 0;
   gboolean force_aspect = FALSE, draw_borders = FALSE;
 
+#if !GLIB_CHECK_VERSION (2, 31, 0)
   if (!g_thread_supported ())
     g_thread_init (NULL);
+#endif
 
   gst_init (&argc, &argv);
   gtk_init (&argc, &argv);
index 210c1ed..a3cd4f9 100644 (file)
@@ -497,8 +497,10 @@ main (int argc, char **argv)
   };
   GOptionContext *ctx;
 
+#if !GLIB_CHECK_VERSION (2, 31, 0)
   if (!g_thread_supported ())
     g_thread_init (NULL);
+#endif
 
   ctx =
       g_option_context_new