[MPlayer-cvslog] CVS: main/libmpdemux demuxer.c,1.187,1.188

Reimar Döffinger CVS syncmail at mplayerhq.hu
Fri May 27 14:38:31 CEST 2005


CVS change done by Reimar Döffinger CVS

Update of /cvsroot/mplayer/main/libmpdemux
In directory mail:/var2/tmp/cvs-serv23242/libmpdemux

Modified Files:
	demuxer.c 
Log Message:
setting sh_audio to NULL is nonsense, since it is only a local variable,
use d_audio->sh instead.
Fixes crash for incoming/VTS_01_1_orig.VOB, though it still doesn't select
the other audio stream automatically.


Index: demuxer.c
===================================================================
RCS file: /cvsroot/mplayer/main/libmpdemux/demuxer.c,v
retrieving revision 1.187
retrieving revision 1.188
diff -u -r1.187 -r1.188
--- demuxer.c	29 Apr 2005 21:57:05 -0000	1.187
+++ demuxer.c	27 May 2005 12:38:29 -0000	1.188
@@ -1291,14 +1291,14 @@
   demux_open_lmlm4(demuxer);
   if(!ds_fill_buffer(d_video)){
     mp_msg(MSGT_DEMUXER,MSGL_INFO,"LMLM4: " MSGTR_MissingVideoStream);
-    sh_video=NULL;
+    d_video->sh=NULL;
   } else {
     sh_video=d_video->sh;sh_video->ds=d_video;
   }
   if(audio_id!=-2) {
    if(!ds_fill_buffer(d_audio)){
     mp_msg(MSGT_DEMUXER,MSGL_INFO,"LMLM4: " MSGTR_MissingAudioStream);
-    sh_audio=NULL;
+    d_audio->sh=NULL;
    } else {
     sh_audio=d_audio->sh;sh_audio->ds=d_audio;
    }
@@ -1319,7 +1319,7 @@
   if(d_video->id != -2) {
     if(!ds_fill_buffer(d_video)){
       mp_msg(MSGT_DEMUXER,MSGL_WARN,"ASF: " MSGTR_MissingVideoStream);
-      sh_video=NULL;
+      d_video->sh=NULL;
       //printf("ASF: missing video stream!? contact the author, it may be a bug :(\n");
     } else {
       sh_video=d_video->sh;sh_video->ds=d_video;
@@ -1331,7 +1331,7 @@
     mp_msg(MSGT_DEMUXER,MSGL_V,MSGTR_ASFSearchingForAudioStream,d_audio->id);
     if(!ds_fill_buffer(d_audio)){
       mp_msg(MSGT_DEMUXER,MSGL_INFO,"ASF: " MSGTR_MissingAudioStream);
-      sh_audio=NULL;
+      d_audio->sh=NULL;
     } else {
       sh_audio=d_audio->sh;sh_audio->ds=d_audio;
       sh_audio->format=sh_audio->wf->wFormatTag;
@@ -1342,7 +1342,7 @@
  case DEMUXER_TYPE_H264_ES:
  case DEMUXER_TYPE_MPEG4_ES:
  case DEMUXER_TYPE_MPEG_ES: {
-   sh_audio=NULL;   // ES streams has no audio channel
+   d_audio->sh=NULL;   // ES streams has no audio channel
    d_video->sh=new_sh_video(demuxer,0); // create dummy video stream header, id=0
    sh_video=d_video->sh;sh_video->ds=d_video;
    break;
@@ -1356,7 +1356,7 @@
   if(audio_id!=-2) {
    if(!ds_fill_buffer(d_audio)){
     mp_msg(MSGT_DEMUXER,MSGL_INFO,"MPEG: " MSGTR_MissingAudioStream);
-    sh_audio=NULL;
+    d_audio->sh=NULL;
    } else {
     sh_audio=d_audio->sh;sh_audio->ds=d_audio;
    }




More information about the MPlayer-cvslog mailing list