diff options
Diffstat (limited to 'libmpdemux')
-rw-r--r-- | libmpdemux/demux_avi.c | 9 | ||||
-rw-r--r-- | libmpdemux/demuxer.c | 5 |
2 files changed, 14 insertions, 0 deletions
diff --git a/libmpdemux/demux_avi.c b/libmpdemux/demux_avi.c index 4f924cffd4..cc6acd5b4c 100644 --- a/libmpdemux/demux_avi.c +++ b/libmpdemux/demux_avi.c @@ -726,4 +726,13 @@ void demux_seek_avi(demuxer_t *demuxer,float rel_seek_secs,int flags){ } +void demux_close_avi(demuxer_t *demuxer) { + avi_priv_t* priv=demuxer->priv; + if(!priv) + return; + + if(priv->idx_size > 0) + free(priv->idx); + free(priv); +} diff --git a/libmpdemux/demuxer.c b/libmpdemux/demuxer.c index 1c36517eaf..22af609995 100644 --- a/libmpdemux/demuxer.c +++ b/libmpdemux/demuxer.c @@ -149,6 +149,7 @@ extern void demux_close_nuv(demuxer_t* demuxer); extern void demux_close_audio(demuxer_t* demuxer); extern void demux_close_ogg(demuxer_t* demuxer); extern void demux_close_demuxers(demuxer_t* demuxer); +extern void demux_close_avi(demuxer_t *demuxer); void free_demuxer(demuxer_t *demuxer){ int i; @@ -178,6 +179,10 @@ void free_demuxer(demuxer_t *demuxer){ demux_close_ogg(demuxer); break; case DEMUXER_TYPE_DEMUXERS: demux_close_demuxers(demuxer); return; + case DEMUXER_TYPE_AVI: + case DEMUXER_TYPE_AVI_NI: + case DEMUXER_TYPE_AVI_NINI: + demux_close_avi(demuxer); return; } // free streams: for(i=0;i<256;i++){ |