[MPlayer-cvslog] r24844 - trunk/input/input.c

ulion subversion at mplayerhq.hu
Tue Oct 23 02:44:23 CEST 2007


Author: ulion
Date: Tue Oct 23 02:44:22 2007
New Revision: 24844

Log:
Fix input command parser for using only tab to separate the arguments.


Modified:
   trunk/input/input.c

Modified: trunk/input/input.c
==============================================================================
--- trunk/input/input.c	(original)
+++ trunk/input/input.c	Tue Oct 23 02:44:22 2007
@@ -754,8 +754,8 @@ mp_input_parse_cmd(char* str) {
   ptr = str;
 
   for(i=0; ptr && i < MP_CMD_MAX_ARGS; i++) {
-    ptr = strchr(ptr,' ');
-    if(!ptr) break;
+    while(ptr[0] != ' ' && ptr[0] != '\t' && ptr[0] != '\0') ptr++;
+    if(ptr[0] == '\0') break;
     while(ptr[0] == ' ' || ptr[0] == '\t') ptr++;
     if(ptr[0] == '\0') break;
     cmd->args[i].type = cmd_def->args[i].type;



More information about the MPlayer-cvslog mailing list