[Mplayer-cvslog] CVS: main cfgparser.c,1.33,1.34

Alex Beregszaszi alex at mplayer.dev.hu
Sat Nov 3 20:05:19 CET 2001


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

Modified Files:
	cfgparser.c 
Log Message:
fixed commandline bug: handling '-' as option when '--' unused

Index: cfgparser.c
===================================================================
RCS file: /cvsroot/mplayer/main/cfgparser.c,v
retrieving revision 1.33
retrieving revision 1.34
diff -u -r1.33 -r1.34
--- cfgparser.c	2 Nov 2001 02:55:51 -0000	1.33
+++ cfgparser.c	3 Nov 2001 19:04:58 -0000	1.34
@@ -522,7 +522,7 @@
 	for (i = 1; i < argc; i++) {
 next:
 		opt = argv[i];
-		/* check for -- (no more options id.) except --help ! */
+		/* check for -- (no more options id.) except --help! */
 		if ((*opt == '-') && (*(opt+1) == '-') && (*(opt+2) != 'h'))
 		{
 			no_more_opts = 1;
@@ -535,7 +535,7 @@
 			goto next;
 		}
 			
-		if ((no_more_opts == 0) && (*opt == '-')) /* option */
+		if ((no_more_opts == 0) && (*opt == '-') && (*(opt+1) != 0)) /* option */
 		{
 		    /* remove trailing '-' */
 		    opt++;




More information about the MPlayer-cvslog mailing list