From 64c2c8d542cb76f042795f9fe7812cc837e2a955 Mon Sep 17 00:00:00 2001 From: Daniel Morin Date: Thu, 4 Apr 2024 09:37:47 -0400 Subject: [PATCH] Revert "h264parse: Remove un-needed check on SPS state" This reverts commit 73dedf9a51e70868f6aa029b968f8c7ef6af530e. Part-of: --- subprojects/gst-plugins-bad/gst/videoparsers/gsth264parse.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/subprojects/gst-plugins-bad/gst/videoparsers/gsth264parse.c b/subprojects/gst-plugins-bad/gst/videoparsers/gsth264parse.c index 4a05287c9e..23b0ce09ca 100644 --- a/subprojects/gst-plugins-bad/gst/videoparsers/gsth264parse.c +++ b/subprojects/gst-plugins-bad/gst/videoparsers/gsth264parse.c @@ -1132,6 +1132,10 @@ gst_h264_parse_process_nal (GstH264Parse * h264parse, GstH264NalUnit * nalu) h264parse->header = TRUE; break; case GST_H264_NAL_SEI: + /* expected state: got-sps */ + if (!GST_H264_PARSE_STATE_VALID (h264parse, GST_H264_PARSE_STATE_GOT_SPS)) + return FALSE; + h264parse->header = TRUE; gst_h264_parse_process_sei (h264parse, nalu); /* mark SEI pos */