[MPlayer-cvslog] r20343 - trunk/libmpdemux/demux_avi.c

reimar subversion at mplayerhq.hu
Sat Oct 21 22:48:41 CEST 2006


Author: reimar
Date: Sat Oct 21 22:48:41 2006
New Revision: 20343

Modified:
   trunk/libmpdemux/demux_avi.c

Log:
Avoid crash after "AVI: No audio stream found -> no sound." message,
audio was not correctly disabled.


Modified: trunk/libmpdemux/demux_avi.c
==============================================================================
--- trunk/libmpdemux/demux_avi.c	(original)
+++ trunk/libmpdemux/demux_avi.c	Sat Oct 21 22:48:41 2006
@@ -470,7 +470,7 @@
       }
       if(a_pos==-1){
         mp_msg(MSGT_DEMUX,MSGL_INFO,"AVI_NI: " MSGTR_MissingAudioStream);
-        sh_audio=NULL;
+        d_audio->sh=sh_audio=NULL;
       } else {
         if(force_ni || abs(a_pos-v_pos)>0x100000){  // distance > 1MB
           mp_msg(MSGT_DEMUX,MSGL_INFO,MSGTR_NI_Message,force_ni?MSGTR_NI_Forced:MSGTR_NI_Detected);
@@ -500,7 +500,7 @@
     mp_msg(MSGT_DEMUX,MSGL_V,"AVI: Searching for audio stream (id:%d)\n",d_audio->id);
     if(!priv->audio_streams || !ds_fill_buffer(d_audio)){
       mp_msg(MSGT_DEMUX,MSGL_INFO,"AVI: " MSGTR_MissingAudioStream);
-      sh_audio=NULL;
+      d_audio->sh=sh_audio=NULL;
     } else {
       sh_audio=d_audio->sh;sh_audio->ds=d_audio;
       sh_audio->format=sh_audio->wf->wFormatTag;



More information about the MPlayer-cvslog mailing list