mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-26 19:51:11 +00:00
omxvideoenc: Fix minor race condition when draining after upstream signalled EOS
This commit is contained in:
parent
05e4b48855
commit
e56cff5f2a
1 changed files with 3 additions and 1 deletions
|
@ -838,7 +838,6 @@ gst_omx_video_enc_loop (GstOMXVideoEnc * self)
|
|||
gst_base_video_encoder_finish_frame (GST_BASE_VIDEO_ENCODER (self),
|
||||
frame);
|
||||
}
|
||||
GST_BASE_VIDEO_CODEC_STREAM_UNLOCK (self);
|
||||
|
||||
if ((flow_ret == GST_FLOW_OK && (buf->omx_buf->nFlags & OMX_BUFFERFLAG_EOS))
|
||||
|| flow_ret == GST_FLOW_UNEXPECTED) {
|
||||
|
@ -863,6 +862,8 @@ gst_omx_video_enc_loop (GstOMXVideoEnc * self)
|
|||
if (flow_ret != GST_FLOW_OK)
|
||||
goto flow_error;
|
||||
|
||||
GST_BASE_VIDEO_CODEC_STREAM_UNLOCK (self);
|
||||
|
||||
return;
|
||||
|
||||
component_error:
|
||||
|
@ -904,6 +905,7 @@ flow_error:
|
|||
gst_pad_pause_task (GST_BASE_VIDEO_CODEC_SRC_PAD (self));
|
||||
}
|
||||
self->started = FALSE;
|
||||
GST_BASE_VIDEO_CODEC_STREAM_UNLOCK (self);
|
||||
return;
|
||||
}
|
||||
reconfigure_error:
|
||||
|
|
Loading…
Reference in a new issue