mirror of
https://github.com/xenia-project/FFmpeg.git
synced 2024-11-29 06:20:29 +00:00
Check for avcodec_open codec parameter == NULL and return error in that case
Originally committed as revision 11316 to svn://svn.ffmpeg.org/ffmpeg/trunk
This commit is contained in:
parent
a5baedea01
commit
9c87b8f777
@ -848,7 +848,7 @@ int attribute_align_arg avcodec_open(AVCodecContext *avctx, AVCodec *codec)
|
||||
goto end;
|
||||
}
|
||||
|
||||
if(avctx->codec)
|
||||
if(avctx->codec || !codec)
|
||||
goto end;
|
||||
|
||||
if (codec->priv_data_size > 0) {
|
||||
|
Loading…
Reference in New Issue
Block a user