x264enc, rdtmanager: fix compilation with debugging disabled
authorTim-Philipp Müller <tim.muller@collabora.co.uk>
Fri, 19 Jun 2009 14:01:46 +0000 (15:01 +0100)
committerTim-Philipp Müller <tim.muller@collabora.co.uk>
Fri, 19 Jun 2009 14:01:46 +0000 (15:01 +0100)
ext/x264/gstx264enc.c
gst/realmedia/rdtmanager.c

index 0bcd443..63832c6 100644 (file)
@@ -400,6 +400,7 @@ void
 gst_x264_enc_log_callback (gpointer private, gint level, const char *format,
     va_list args)
 {
+#ifndef GST_DISABLE_GST_DEBUG
   GstDebugLevel gst_level;
   GObject *object = (GObject *) private;
 
@@ -424,6 +425,7 @@ gst_x264_enc_log_callback (gpointer private, gint level, const char *format,
 
   gst_debug_log_valist (x264_enc_debug, gst_level, "", "", 0, object, format,
       args);
+#endif /* GST_DISABLE_GST_DEBUG */
 }
 
 /* initialize the new element
@@ -488,7 +490,7 @@ gst_x264_enc_init (GstX264Enc * encoder, GstX264EncClass * klass)
   x264_param_default (&encoder->x264param);
 
   /* log callback setup; part of parameters */
-  encoder->x264param.pf_log = GST_DEBUG_FUNCPTR (gst_x264_enc_log_callback);
+  encoder->x264param.pf_log = gst_x264_enc_log_callback;
   encoder->x264param.p_log_private = encoder;
   encoder->x264param.i_log_level = X264_LOG_DEBUG;
 
index b4bf3af..2c1158f 100644 (file)
@@ -874,9 +874,8 @@ do_eos:
   }
 pause:
   {
-    const gchar *reason = gst_flow_get_name (result);
-
-    GST_DEBUG_OBJECT (rdtmanager, "pausing task, reason %s", reason);
+    GST_DEBUG_OBJECT (rdtmanager, "pausing task, reason %s",
+        gst_flow_get_name (result));
 
     JBUF_LOCK (session);
     /* store result */