mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-01-31 03:29:50 +00:00
cudacompositor: Fix memory leak
gst_cuda_compositor_upload_frame() returns buffers with increased refcount already Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8335>
This commit is contained in:
parent
9b578abe15
commit
dc81abe9ee
1 changed files with 2 additions and 2 deletions
|
@ -663,10 +663,10 @@ gst_cuda_compositor_pad_prepare_frame (GstVideoAggregatorPad * pad,
|
||||||
&pad->info, buffer, (GstMapFlags) (GST_MAP_READ | GST_MAP_CUDA))) {
|
&pad->info, buffer, (GstMapFlags) (GST_MAP_READ | GST_MAP_CUDA))) {
|
||||||
GST_ERROR_OBJECT (self, "Couldn't map frame");
|
GST_ERROR_OBJECT (self, "Couldn't map frame");
|
||||||
gst_buffer_unref (buffer);
|
gst_buffer_unref (buffer);
|
||||||
|
return FALSE;
|
||||||
}
|
}
|
||||||
|
|
||||||
prepared_frame->buffer = buffer;
|
priv->prepared_buf = buffer;
|
||||||
priv->prepared_buf = gst_buffer_ref (buffer);
|
|
||||||
|
|
||||||
return TRUE;
|
return TRUE;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue