[MPlayer-cvslog] CVS: main mplayer.c,1.928,1.929

Reimar Döffinger CVS syncmail at mplayerhq.hu
Sat Apr 15 11:36:56 CEST 2006


CVS change done by Reimar Döffinger CVS

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

Modified Files:
	mplayer.c 
Log Message:
do not try to load default.sub when it doesn't exist. Fixes bug #480.


Index: mplayer.c
===================================================================
RCS file: /cvsroot/mplayer/main/mplayer.c,v
retrieving revision 1.928
retrieving revision 1.929
diff -u -r1.928 -r1.929
--- mplayer.c	14 Apr 2006 10:57:41 -0000	1.928
+++ mplayer.c	15 Apr 2006 09:36:53 -0000	1.929
@@ -3111,7 +3111,10 @@
     free(tmp);
     if (set_of_sub_size == 0)
     {
-        add_subtitles (mem_ptr=get_path("default.sub"), sh_video->fps, 1);
+        struct stat st;
+        mem_ptr = get_path("default.sub");
+        if (stat(mem_ptr, &st) == 0)
+            add_subtitles (mem_ptr, sh_video->fps, 0);
     free(mem_ptr); // release the buffer created by get_path()
     }
   }




More information about the MPlayer-cvslog mailing list