ffmpeg | branch: master | Pavel Koshevoy <pkoshe...@gmail.com> | Thu Feb 9 20:20:14 2017 -0700| [e3f1b993341ec9ed542b07c4558baeea6921ed53] | committer: Michael Niedermayer
lavc/vda_h264_dec.c Fix NULL pointer dereference ps.sps_list entries may be NULL, so check before dereferencing Signed-off-by: Michael Niedermayer <mich...@niedermayer.cc> > http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=e3f1b993341ec9ed542b07c4558baeea6921ed53 --- libavcodec/vda_h264_dec.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libavcodec/vda_h264_dec.c b/libavcodec/vda_h264_dec.c index 92839e2..972bd6b 100644 --- a/libavcodec/vda_h264_dec.c +++ b/libavcodec/vda_h264_dec.c @@ -226,7 +226,7 @@ static av_cold int vdadec_init(AVCodecContext *avctx) ctx->h264_initialized = 1; for (i = 0; i < MAX_SPS_COUNT; i++) { - const SPS *sps = (const SPS*)ctx->h264ctx.ps.sps_list[i]->data; + const SPS *sps = ctx->h264ctx.ps.sps_list[i] ? (const SPS*)ctx->h264ctx.ps.sps_list[i]->data : NULL; if (sps && (sps->bit_depth_luma != 8 || sps->chroma_format_idc == 2 || sps->chroma_format_idc == 3)) { _______________________________________________ ffmpeg-cvslog mailing list ffmpeg-cvslog@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-cvslog