va: Fix error handling for base transform

Need to check the returned value of gst_buffer_pool_set_active() when
setting the active status of buffer pool.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/1131>
This commit is contained in:
Mengkejiergeli Ba 2021-10-12 17:44:27 +08:00 committed by GStreamer Marge Bot
parent 4be5c7ce0a
commit 2eaba0cefa

View file

@ -729,7 +729,11 @@ _get_sinkpad_pool (GstVaBaseTransform * self)
gst_object_unref (allocator);
gst_buffer_pool_set_active (self->priv->sinkpad_pool, TRUE);
if (!gst_buffer_pool_set_active (self->priv->sinkpad_pool, TRUE)) {
GST_WARNING_OBJECT (self, "failed to active the sinkpad pool %"
GST_PTR_FORMAT, self->priv->sinkpad_pool);
return NULL;
}
return self->priv->sinkpad_pool;
}