gst-launch: fix compiler warnings for SIGHUP handlers on windows
authorTim-Philipp Müller <tim@centricular.com>
Thu, 20 Jul 2017 16:31:41 +0000 (17:31 +0100)
committerTim-Philipp Müller <tim@centricular.com>
Thu, 20 Jul 2017 16:31:41 +0000 (17:31 +0100)
Fix unused variable/function compiler warnings on windows.
The SIGHUP handling is only available under unix.

https://bugzilla.gnome.org/show_bug.cgi?id=783661

tools/gst-launch.c

index 98111db..f19b0dc 100644 (file)
@@ -466,9 +466,11 @@ print_toc_entry (gpointer data, gpointer user_data)
   g_list_foreach (subentries, print_toc_entry, GUINT_TO_POINTER (indent));
 }
 
+#ifdef G_OS_UNIX
+static guint signal_watch_hup_id;
+#endif
 #if defined(G_OS_UNIX) || defined(G_OS_WIN32)
 static guint signal_watch_intr_id;
-static guint signal_watch_hup_id;
 #if defined(G_OS_WIN32)
 static GstElement *intr_pipeline;
 #endif
@@ -495,6 +497,7 @@ intr_handler (gpointer user_data)
   return G_SOURCE_REMOVE;
 }
 
+#ifdef G_OS_UNIX
 static gboolean
 hup_handler (gpointer user_data)
 {
@@ -513,6 +516,7 @@ hup_handler (gpointer user_data)
 
   return G_SOURCE_CONTINUE;
 }
+#endif
 
 #if defined(G_OS_WIN32)         /* G_OS_UNIX */
 static BOOL WINAPI