[0.11] gstreamer: pad: fix buffer/event leak when pad is flushing

René Stadler cymacs at kemper.freedesktop.org
Mon Oct 17 12:41:37 PDT 2011


Module: gstreamer
Branch: 0.11
Commit: 5239679c091adf8dce930d2843720996b9ea1ddf
URL:    http://cgit.freedesktop.org/gstreamer/gstreamer/commit/?id=5239679c091adf8dce930d2843720996b9ea1ddf

Author: René Stadler <rene.stadler at collabora.co.uk>
Date:   Mon Oct 17 21:37:17 2011 +0200

pad: fix buffer/event leak when pad is flushing

Apparently this got lost while refactoring probes.

---

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

diff --git a/gst/gstpad.c b/gst/gstpad.c
index 6cd895b..7f85954 100644
--- a/gst/gstpad.c
+++ b/gst/gstpad.c
@@ -3640,6 +3640,7 @@ flushing:
         "chaining, but pad was flushing");
     GST_OBJECT_UNLOCK (pad);
     GST_PAD_STREAM_UNLOCK (pad);
+    gst_mini_object_unref (GST_MINI_OBJECT_CAST (data));
     return GST_FLOW_WRONG_STATE;
   }
 events_error:
@@ -3647,6 +3648,7 @@ events_error:
     GST_CAT_LOG_OBJECT (GST_CAT_SCHEDULING, pad, "events were not accepted");
     GST_OBJECT_UNLOCK (pad);
     GST_PAD_STREAM_UNLOCK (pad);
+    gst_mini_object_unref (GST_MINI_OBJECT_CAST (data));
     return ret;
   }
 probe_stopped:



More information about the gstreamer-commits mailing list