mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-04-26 06:54:49 +00:00
compositor: Don't leak all buffers while crossfading and not all pads are crossfading
This commit is contained in:
parent
9a34dd8c2a
commit
84a956768d
1 changed files with 5 additions and 0 deletions
|
@ -833,8 +833,13 @@ gst_compositor_fill_transparent (GstCompositor * self, GstVideoFrame * frame,
|
||||||
|
|
||||||
if (!gst_video_frame_map (nframe, &frame->info, cbuffer, GST_MAP_WRITE)) {
|
if (!gst_video_frame_map (nframe, &frame->info, cbuffer, GST_MAP_WRITE)) {
|
||||||
GST_WARNING_OBJECT (self, "Could not map output buffer");
|
GST_WARNING_OBJECT (self, "Could not map output buffer");
|
||||||
|
gst_buffer_unref (cbuffer);
|
||||||
return GST_FLOW_ERROR;
|
return GST_FLOW_ERROR;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* the last reference is owned by the frame and released once the frame
|
||||||
|
* is unmapped. We leak it if we don't unref here */
|
||||||
|
gst_buffer_unref (cbuffer);
|
||||||
} else {
|
} else {
|
||||||
nframe = frame;
|
nframe = frame;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue