The pool accesses data from the v4l2object so it must exist at least
as long as the pool. Refcount the element which controls the object
live-time.
https://bugzilla.gnome.org/show_bug.cgi?id=701650
gst_object_unref (pool->allocator);
g_free (pool->buffers);
+ gst_object_unref (pool->obj->element);
+
G_OBJECT_CLASS (parent_class)->finalize (object);
}
gst_buffer_pool_config_set_params (s, caps, obj->sizeimage, 2, 0);
gst_buffer_pool_set_config (GST_BUFFER_POOL_CAST (pool), s);
+ gst_object_ref (obj->element);
+
return GST_BUFFER_POOL (pool);
/* ERRORS */