mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-01-11 18:05:37 +00:00
v4l2transform: don't segfault if flushed without pools
The v4l2output and v4l2capture v4l2objects can have pool == NULL if they have been stopped before.
This commit is contained in:
parent
39d32b2394
commit
cdf15e9032
1 changed files with 4 additions and 2 deletions
|
@ -991,8 +991,10 @@ gst_v4l2_transform_sink_event (GstBaseTransform * trans, GstEvent * event)
|
||||||
GST_DEBUG_OBJECT (self, "flush stop");
|
GST_DEBUG_OBJECT (self, "flush stop");
|
||||||
gst_v4l2_object_unlock_stop (self->v4l2capture);
|
gst_v4l2_object_unlock_stop (self->v4l2capture);
|
||||||
gst_v4l2_object_unlock_stop (self->v4l2output);
|
gst_v4l2_object_unlock_stop (self->v4l2output);
|
||||||
gst_v4l2_buffer_pool_flush (self->v4l2output->pool);
|
if (self->v4l2output->pool)
|
||||||
gst_v4l2_buffer_pool_flush (self->v4l2capture->pool);
|
gst_v4l2_buffer_pool_flush (self->v4l2output->pool);
|
||||||
|
if (self->v4l2capture->pool)
|
||||||
|
gst_v4l2_buffer_pool_flush (self->v4l2capture->pool);
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
break;
|
break;
|
||||||
|
|
Loading…
Reference in a new issue