Mercurial > mplayer.hg
changeset 13520:5f4f9de738b2
fixed small memleak
author | reimar |
---|---|
date | Fri, 01 Oct 2004 19:51:03 +0000 |
parents | 6bf63a7524d8 |
children | b6e85e7ec3a6 |
files | libao2/audio_out.c libmpdemux/demuxer.c |
diffstat | 2 files changed, 5 insertions(+), 3 deletions(-) [+] |
line wrap: on
line diff
--- a/libao2/audio_out.c Fri Oct 01 15:53:09 2004 +0000 +++ b/libao2/audio_out.c Fri Oct 01 19:51:03 2004 +0000 @@ -156,6 +156,7 @@ } } // continue... + free(ao); ++ao_list; if(!(ao_list[0])) return NULL; // do NOT fallback to others }
--- a/libmpdemux/demuxer.c Fri Oct 01 15:53:09 2004 +0000 +++ b/libmpdemux/demuxer.c Fri Oct 01 19:51:03 2004 +0000 @@ -703,11 +703,12 @@ if(id==formtypeAVI){ mp_msg(MSGT_DEMUXER,MSGL_INFO,MSGTR_Detected_XXX_FileFormat,"AVI"); file_format=DEMUXER_TYPE_AVI; - } else { - free_demuxer(demuxer); - demuxer = NULL; } } + if (file_format==DEMUXER_TYPE_UNKNOWN) { + free_demuxer(demuxer); + demuxer = NULL; + } } } //=============== Try to open as Y4M file: =================