[MPlayer-cvslog] CVS: main mencoder.c,1.300,1.301

Reimar Döffinger CVS syncmail at mplayerhq.hu
Fri Jul 22 23:27:57 CEST 2005


CVS change done by Reimar Döffinger CVS

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

Modified Files:
	mencoder.c 
Log Message:
fix invalid pointers passed to init_audio_filters


Index: mencoder.c
===================================================================
RCS file: /cvsroot/mplayer/main/mencoder.c,v
retrieving revision 1.300
retrieving revision 1.301
diff -u -r1.300 -r1.301
--- mencoder.c	22 Jul 2005 17:11:39 -0000	1.300
+++ mencoder.c	22 Jul 2005 21:27:54 -0000	1.301
@@ -986,12 +986,15 @@
 			}
 			break;
 	}
-	if (do_init_filters) if(!init_audio_filters(sh_audio,
+	if (do_init_filters) {
+	  int out_srate = mux_a->wf->nSamplesPerSec;
+	  int out_channels = mux_a->wf->nChannels;
+	  if(!init_audio_filters(sh_audio,
 	    new_srate,
 	    sh_audio->channels,
 	    sh_audio->sample_format,
-	    &mux_a->wf->nSamplesPerSec,
-	    &mux_a->wf->nChannels,
+	    &out_srate,
+	    &out_channels,
 	    &out_format,
 	    out_minsize,
 	    out_maxsize))
@@ -999,6 +1002,9 @@
 		mp_msg(MSGT_CPLAYER, MSGL_FATAL, MSGTR_NoMatchingFilter);
 		mencoder_exit(1, NULL);
 	}
+	  mux_a->wf->nSamplesPerSec = out_srate;
+	  mux_a->wf->nChannels = out_channels;
+	}
 }
 
 parse_end_at();




More information about the MPlayer-cvslog mailing list