avcodec/h264_slice: Remove dead sps check

Fixes: CID1439574 Dereference after null check

Sponsored-by: Sovereign Tech Fund
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
(cherry picked from commit a68aa951b2)
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
release/6.1
Michael Niedermayer 10 months ago
parent 2de1f26366
commit 61f5019a51
No known key found for this signature in database
GPG Key ID: B18E8928B3948D64
  1. 2
      libavcodec/h264_slice.c

@ -1398,7 +1398,7 @@ static int h264_field_start(H264Context *h, const H264SliceContext *sl,
sps = h->ps.sps; 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) {
h->avctx->has_b_frames = sps->num_reorder_frames; h->avctx->has_b_frames = sps->num_reorder_frames;
} }

Loading…
Cancel
Save