Mercurial > mplayer.hg
diff libmpdemux/demux_lavf.c @ 36310:7b135b3b8b38
Avoid dereferencing NULL pointer on close if we
never allocated a AVIOContext.
author | reimar |
---|---|
date | Mon, 05 Aug 2013 18:57:04 +0000 |
parents | 97638800c6f3 |
children | 139f2b064ef9 |
line wrap: on
line diff
--- a/libmpdemux/demux_lavf.c Mon Aug 05 18:36:57 2013 +0000 +++ b/libmpdemux/demux_lavf.c Mon Aug 05 18:57:04 2013 +0000 @@ -872,7 +872,7 @@ av_freep(&priv->avfc->key); avformat_close_input(&priv->avfc); } - av_freep(&priv->pb->buffer); + if (priv->pb) av_freep(&priv->pb->buffer); av_freep(&priv->pb); free(priv); demuxer->priv= NULL; }