Mercurial > mplayer.hg
changeset 23295:ab885f928444
Fix double free() in demux_asf.c
If demux_open_asf() fails it frees the demuxer->priv field before
returning. Then demuxer.c calls demux_close_asf() which frees the field
again. Fix by removing the free() in demux_open_asf().
author | uau |
---|---|
date | Mon, 14 May 2007 01:23:54 +0000 |
parents | 30c61fe726bf |
children | 902c817e82be |
files | libmpdemux/demux_asf.c |
diffstat | 1 files changed, 1 insertions(+), 3 deletions(-) [+] |
line wrap: on
line diff
--- a/libmpdemux/demux_asf.c Mon May 14 01:23:52 2007 +0000 +++ b/libmpdemux/demux_asf.c Mon May 14 01:23:54 2007 +0000 @@ -701,10 +701,8 @@ //---- ASF header: if(!asf) return NULL; init_priv(asf); - if (!read_asf_header(demuxer,asf)) { - free(asf); + if (!read_asf_header(demuxer,asf)) return NULL; - } stream_reset(demuxer->stream); stream_seek(demuxer->stream,demuxer->movi_start); // demuxer->idx_pos=0;