mpeg2: verify bug 749607 patches
@vjaquez
Submitted by Víctor Manuel Jáquez Leal Link to original bug (#750221)
Description
There doubts in these two commits (bug 749607):
commit d6255be9
Author: Víctor Manuel Jáquez Leal victorx.jaquez@intel.com
Date: Wed May 27 10:49:56 2015 +0200
mpeg2: avoid crash when seeking with debug logs
Move down the debug message when the state of the decoder is verified
so the slice header is not NULL.
commit f1a60ec6
Author: Jan Schmidt jan@centricular.com
Date: Wed Dec 17 00:41:10 2014 +1100
mpeg2: Avoid crashes and warnings on re-opened decoder after a seek
Reset state and add some checks for safe state to avoid a crash and
a warning after the decoder is destroyed/recreated during a seek.
In commit d6255be9
(In reply to Gwenole Beauchesne from comment 13)
It would be better to know why slice_hdr or unit is NULL. Committing this is
just hiding the core issue more...
In commit f1a60ec6 (from discussion in https://github.com/thaytan/gstreamer-vaapi/commit/b84e65ada15f9396b8c9ab507c1cb5f10c3f3914)
- if (!is_valid_state(decoder, GST_MPEG_VIDEO_STATE_VALID_PIC_HEADERS))
return GST_VAAPI_DECODER_STATUS_SUCCESS;
This part should not be necessary. This is already tracked at decode time. I
would just push the two other hunks.
This bug is to verify if those changeset are correct or not.