gst/playback/gststreamselector.c: Don't leak pad name.
authorTim-Philipp Müller <tim@centricular.net>
Tue, 11 Apr 2006 10:45:32 +0000 (10:45 +0000)
committerTim-Philipp Müller <tim@centricular.net>
Tue, 11 Apr 2006 10:45:32 +0000 (10:45 +0000)
Original commit message from CVS:
* gst/playback/gststreamselector.c:
(gst_stream_selector_get_property):
Don't leak pad name.

ChangeLog
gst/playback/gststreamselector.c

index b765aa5..60eece8 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,9 @@
+2006-04-11  Tim-Philipp Müller  <tim at centricular dot net>
+
+       * gst/playback/gststreamselector.c:
+       (gst_stream_selector_get_property):
+         Don't leak pad name.
+
 2006-04-10  Michael Smith  <msmith@fluendo.com>
 
        * tests/check/Makefile.am:
index 3aac714..c68245f 100644 (file)
@@ -236,9 +236,10 @@ gst_stream_selector_get_property (GObject * object, guint prop_id,
     case PROP_ACTIVE_PAD:{
       GST_OBJECT_LOCK (object);
       if (sel->active_sinkpad != NULL) {
-        g_value_set_string (value, gst_pad_get_name (sel->active_sinkpad));
-      } else
+        g_value_take_string (value, gst_pad_get_name (sel->active_sinkpad));
+      } else {
         g_value_set_string (value, "");
+      }
       GST_OBJECT_UNLOCK (object);
       break;
     }