From fe9e2844639fa559a90131ad629eed0ace917f30 Mon Sep 17 00:00:00 2001 From: Wim Taymans Date: Fri, 27 Jan 2012 15:32:37 +0100 Subject: [PATCH] queue2: fix memory leak unmap the buffer memory on errors. --- plugins/elements/gstqueue2.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/plugins/elements/gstqueue2.c b/plugins/elements/gstqueue2.c index 524c6ed..8c26224 100644 --- a/plugins/elements/gstqueue2.c +++ b/plugins/elements/gstqueue2.c @@ -1288,12 +1288,14 @@ gst_queue2_create_read (GstQueue2 * queue, guint64 offset, guint length, hit_eos: { GST_DEBUG_OBJECT (queue, "EOS hit and we don't have any requested data"); + gst_buffer_unmap (buf, &info); gst_buffer_unref (buf); return GST_FLOW_EOS; } out_flushing: { GST_DEBUG_OBJECT (queue, "we are flushing"); + gst_buffer_unmap (buf, &info); gst_buffer_unref (buf); return GST_FLOW_WRONG_STATE; } -- 2.7.4