Mercurial > mplayer.hg
changeset 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 | 583523331410 |
children | 9fab03575b89 |
files | libmpdemux/demux_lavf.c |
diffstat | 1 files changed, 1 insertions(+), 1 deletions(-) [+] |
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; }