[Mplayer-cvslog] CVS: main mplayer.c,1.242,1.243

Adam Tla/lka atlka at mplayer.dev.hu
Tue Aug 28 10:06:38 CEST 2001


Update of /cvsroot/mplayer/main
In directory mplayer:/var/tmp.root/cvs-serv5374

Modified Files:
	mplayer.c 
Log Message:

checking range of vo_osd_progbar_value added


Index: mplayer.c
===================================================================
RCS file: /cvsroot/mplayer/main/mplayer.c,v
retrieving revision 1.242
retrieving revision 1.243
diff -u -r1.242 -r1.243
--- mplayer.c	27 Aug 2001 23:56:43 -0000	1.242
+++ mplayer.c	28 Aug 2001 08:06:26 -0000	1.243
@@ -1762,7 +1762,11 @@
         if(len>0){
           osd_visible=sh_video->fps; // 1 sec
           vo_osd_progbar_type=0;
-          vo_osd_progbar_value=(demuxer->filepos-demuxer->movi_start)/len;
+	  vo_osd_progbar_value=(demuxer->filepos-demuxer->movi_start)/len;
+	  if (vo_osd_progbar_value<0)
+	     vo_osd_progbar_value=0;
+	  else if (vo_osd_progbar_value>255)
+	     vo_osd_progbar_value=255;
         }
       }
 #endif




More information about the MPlayer-cvslog mailing list