gstreamer: Drop incorrect unref on caps

The caps object passeed to the gst_libcamera_create_video_pool()
function is managed as a g_autoptr() in the caller. The function doesn't
acquire any new reference, so it shouldn't call gst_caps_unref(). Fix
it.

Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Reviewed-by: Nicolas Dufresne <nicolas.dufresne@collabora.com>
This commit is contained in:
Laurent Pinchart 2025-06-04 02:36:01 +03:00
parent 772b06bd8c
commit a8f90517e0

View file

@ -580,7 +580,6 @@ gst_libcamera_create_video_pool(GstLibcameraSrc *self, GstPad *srcpad,
} }
if (!gst_buffer_pool_set_active(pool, true)) { if (!gst_buffer_pool_set_active(pool, true)) {
gst_caps_unref(caps);
GST_ELEMENT_ERROR(self, RESOURCE, SETTINGS, GST_ELEMENT_ERROR(self, RESOURCE, SETTINGS,
("Failed to active buffer pool"), ("Failed to active buffer pool"),
("gst_libcamera_src_negotiate() failed.")); ("gst_libcamera_src_negotiate() failed."));