mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-26 19:51:11 +00:00
d3d11decoder: Fix crash on negotiate() when decoder is not configured
The negotiate() can be called by GstVideoDecoder baseclass on GAP event, and decoder helper object might not be configured at the time when negotiate() is called. Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5401>
This commit is contained in:
parent
ca2f7a4254
commit
c7f7c8e346
1 changed files with 5 additions and 0 deletions
|
@ -1686,6 +1686,11 @@ gst_d3d11_decoder_negotiate (GstD3D11Decoder * decoder,
|
|||
info = &decoder->output_info;
|
||||
input_state = decoder->input_state;
|
||||
|
||||
if (!decoder->configured) {
|
||||
GST_WARNING_OBJECT (videodec, "Decoder is not configured");
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
alternate_interlaced =
|
||||
(GST_VIDEO_INFO_INTERLACE_MODE (info) ==
|
||||
GST_VIDEO_INTERLACE_MODE_ALTERNATE);
|
||||
|
|
Loading…
Reference in a new issue