mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-12-23 16:50:47 +00:00
mfc: Set variables to NULL to prevent usage after free/unref
This commit is contained in:
parent
b244151f85
commit
f5ef0dd7ee
1 changed files with 4 additions and 0 deletions
|
@ -804,6 +804,7 @@ gst_mfc_dec_dequeue_output (GstMFCDec * self)
|
|||
"Dropping too late frame: deadline %" G_GINT64_FORMAT, deadline);
|
||||
ret = gst_video_decoder_drop_frame (GST_VIDEO_DECODER (self), frame);
|
||||
frame = NULL;
|
||||
outbuf = NULL;
|
||||
goto done;
|
||||
}
|
||||
|
||||
|
@ -858,6 +859,9 @@ gst_mfc_dec_dequeue_output (GstMFCDec * self)
|
|||
if (state)
|
||||
gst_video_codec_state_unref (state);
|
||||
|
||||
frame = NULL;
|
||||
outbuf = NULL;
|
||||
|
||||
if (ret != GST_FLOW_OK)
|
||||
break;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue