summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLaurent Glayal <spglegle@yahoo.fr>2007-06-05 13:41:54 +0000
committerWim Taymans <wim.taymans@gmail.com>2007-06-05 13:41:54 +0000
commit991730660c8b69daadbdca8cf1009a16b0bccc37 (patch)
tree0cd75015c033721553b0dc3135540afd3ba2213c
parentc413858fe6c795c9191f475c6a2db88c824ba2f3 (diff)
ext/ffmpeg/gstffmpegscale.c: don't leak refcounts in event handler. Fixes #444332.
Original commit message from CVS: Patch by: Laurent Glayal <spglegle at yahoo dot fr> * ext/ffmpeg/gstffmpegscale.c: (gst_ffmpegscale_handle_src_event): don't leak refcounts in event handler. Fixes #444332.
-rw-r--r--ChangeLog7
-rw-r--r--ext/ffmpeg/gstffmpegscale.c11
2 files changed, 16 insertions, 2 deletions
diff --git a/ChangeLog b/ChangeLog
index 789313e..5bd8046 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,10 @@
+2007-06-05 Wim Taymans <wim@fluendo.com>
+
+ Patch by: Laurent Glayal <spglegle at yahoo dot fr>
+
+ * ext/ffmpeg/gstffmpegscale.c: (gst_ffmpegscale_handle_src_event):
+ don't leak refcounts in event handler. Fixes #444332.
+
2007-05-25 Wim Taymans <wim@fluendo.com>
* ext/ffmpeg/gstffmpegdec.c: (clip_video_buffer),
diff --git a/ext/ffmpeg/gstffmpegscale.c b/ext/ffmpeg/gstffmpegscale.c
index 0868907..65ada28 100644
--- a/ext/ffmpeg/gstffmpegscale.c
+++ b/ext/ffmpeg/gstffmpegscale.c
@@ -365,9 +365,12 @@ gst_ffmpegscale_transform (GstBaseTransform * trans, GstBuffer * inbuf,
static gboolean
gst_ffmpegscale_handle_src_event (GstPad * pad, GstEvent * event)
{
- GstFFMpegScale *scale = GST_FFMPEGSCALE (gst_pad_get_parent (pad));
+ GstFFMpegScale *scale;
GstStructure *structure;
gdouble pointer;
+ gboolean res;
+
+ scale = GST_FFMPEGSCALE (gst_pad_get_parent (pad));
switch (GST_EVENT_TYPE (event)) {
case GST_EVENT_NAVIGATION:
@@ -390,7 +393,11 @@ gst_ffmpegscale_handle_src_event (GstPad * pad, GstEvent * event)
break;
}
- return gst_pad_event_default (pad, event);
+ res = gst_pad_event_default (pad, event);
+
+ gst_object_unref (scale);
+
+ return res;
}
gboolean