[FFmpeg-cvslog] avcodec/h264_slice: Remove dead sps check
Michael Niedermayer
git at videolan.org
Sat May 25 01:57:13 EEST 2024
ffmpeg | branch: release/6.1 | Michael Niedermayer <michael at niedermayer.cc> | Mon May 6 03:17:26 2024 +0200| [61f5019a51db0d94fcb7f7fd37d6b1de6b745c6b] | committer: Michael Niedermayer
avcodec/h264_slice: Remove dead sps check
Fixes: CID1439574 Dereference after null check
Sponsored-by: Sovereign Tech Fund
Signed-off-by: Michael Niedermayer <michael at niedermayer.cc>
(cherry picked from commit a68aa951b21b8b7db0a5200bcfebc0a077a5f094)
Signed-off-by: Michael Niedermayer <michael at niedermayer.cc>
> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=61f5019a51db0d94fcb7f7fd37d6b1de6b745c6b
---
libavcodec/h264_slice.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/libavcodec/h264_slice.c b/libavcodec/h264_slice.c
index 5c17edf9a4..aac6f26fb1 100644
--- a/libavcodec/h264_slice.c
+++ b/libavcodec/h264_slice.c
@@ -1398,7 +1398,7 @@ static int h264_field_start(H264Context *h, const H264SliceContext *sl,
sps = h->ps.sps;
- if (sps && sps->bitstream_restriction_flag &&
+ if (sps->bitstream_restriction_flag &&
h->avctx->has_b_frames < sps->num_reorder_frames) {
h->avctx->has_b_frames = sps->num_reorder_frames;
}
More information about the ffmpeg-cvslog
mailing list