aboutsummaryrefslogtreecommitdiffhomepage
path: root/libmpdemux
diff options
context:
space:
mode:
authorGravatar albeu <albeu@b3059339-0415-0410-9bf9-f77b7e298cf2>2002-07-26 12:36:13 +0000
committerGravatar albeu <albeu@b3059339-0415-0410-9bf9-f77b7e298cf2>2002-07-26 12:36:13 +0000
commit419943f3c7d354473913b7348ffa78f1761ea4aa (patch)
tree6e86bff7ecb7593767eae8927f8be4c693fe8608 /libmpdemux
parent6ce6f1d587504999b8fdf4c8b26488f6379fb2a2 (diff)
Add uninit to the avi demuxer
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@6817 b3059339-0415-0410-9bf9-f77b7e298cf2
Diffstat (limited to 'libmpdemux')
-rw-r--r--libmpdemux/demux_avi.c9
-rw-r--r--libmpdemux/demuxer.c5
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++){