changeset 9792:4c34dc17e43d

Exit when the option parser return M_OPT_EXIT
author albeu
date Wed, 02 Apr 2003 16:13:16 +0000
parents c5b63e88253d
children b2bf632d37b5
files parser-mecmd.c parser-mpcmd.c
diffstat 2 files changed, 6 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/parser-mecmd.c	Wed Apr 02 16:11:15 2003 +0000
+++ b/parser-mecmd.c	Wed Apr 02 16:13:16 2003 +0000
@@ -110,6 +110,8 @@
 	    no++;
 	  } else {
 //	    mp_msg(MSGT_CFGPARSER, MSGL_ERR, "m_config_set_option() failed (%d)\n",tmp);
+	    if(tmp == M_OPT_EXIT)
+	      exit(0);
 	    goto err_out;
 	  }
 	}
--- a/parser-mpcmd.c	Wed Apr 02 16:11:15 2003 +0000
+++ b/parser-mpcmd.c	Wed Apr 02 16:13:16 2003 +0000
@@ -186,8 +186,11 @@
 	  }
 	}
 
-	if (tmp < 0)
+	if (tmp < 0) {
+	  if (tmp == M_OPT_EXIT)
+	    exit(0);
 	  goto err_out;
+	}
 	i += tmp;
       }
     else /* filename */