[gst-cvs] gst-plugins-base: playbin2: Don' t leak the GError and debug string when parsing error messages

Sebastian Dröge slomo at kemper.freedesktop.org
Sat Nov 14 05:08:52 PST 2009


Module: gst-plugins-base
Branch: master
Commit: 16dec615cb42a8ecb7495639b8dbf0b37cd9b91b
URL:    http://cgit.freedesktop.org/gstreamer/gst-plugins-base/commit/?id=16dec615cb42a8ecb7495639b8dbf0b37cd9b91b

Author: Sebastian Dröge <sebastian.droege at collabora.co.uk>
Date:   Fri Nov 13 12:47:55 2009 +0100

playbin2: Don't leak the GError and debug string when parsing error messages

---

 gst/playback/gstplaybin2.c |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)

diff --git a/gst/playback/gstplaybin2.c b/gst/playback/gstplaybin2.c
index f6f9600..209008f 100644
--- a/gst/playback/gstplaybin2.c
+++ b/gst/playback/gstplaybin2.c
@@ -2017,6 +2017,8 @@ gst_play_bin_handle_message (GstBin * bin, GstMessage * msg)
       new_msg = gst_message_new_warning (msg->src, err, debug);
 
       gst_message_unref (msg);
+      g_error_free (err);
+      g_free (debug);
       msg = new_msg;
 
       REMOVE_SIGNAL (group->suburidecodebin, group->sub_pad_added_id);





More information about the Gstreamer-commits mailing list