summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMatej Knopp <matej.knopp@gmail.com>2014-10-02 03:30:24 +0200
committerSebastian Dröge <sebastian@centricular.com>2014-10-02 10:39:54 +0300
commit5e8b4bf085180f7a4c7ae6ec0f525baeaedd4df8 (patch)
treefca5d0745f07e7ab567a98037ab3fb460039f355
parent798cafa7fc2716478d4e3bbcdfd2c89340c7ecc5 (diff)
baseparse: don't leak caps in gst_base_parse_process_streamheader
https://bugzilla.gnome.org/show_bug.cgi?id=737762
-rw-r--r--libs/gst/base/gstbaseparse.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/libs/gst/base/gstbaseparse.c b/libs/gst/base/gstbaseparse.c
index 8fd1103409..7f29afaf1a 100644
--- a/libs/gst/base/gstbaseparse.c
+++ b/libs/gst/base/gstbaseparse.c
@@ -2756,10 +2756,16 @@ gst_base_parse_process_streamheader (GstBaseParse * parse)
GST_OBJECT_CAST (parse), gst_buffer_ref (buffer));
}
+ gst_caps_unref (caps);
+
return ret;
notfound:
{
+ if (caps) {
+ gst_caps_unref (caps);
+ }
+
GST_DEBUG_OBJECT (parse, "No streamheader on caps");
return GST_FLOW_OK;
}