version 1.46 | | version 1.47 |
---|
| | |
/* | | /* |
* static char *rcsid_commands_c = | | * static char *rcsid_commands_c = |
* "$Id: commands.c,v 1.46 2004/11/25 18:47:58 ryo_saeba Exp $"; | | * "$Id: commands.c,v 1.47 2005/01/16 11:31:38 tchize Exp $"; |
*/ | | */ |
| | |
/* | | /* |
| | |
#ifdef INPUT_DEBUG | | #ifdef INPUT_DEBUG |
LOG(llevDebug, "Command: '%s'\n", str); | | LOG(llevDebug, "Command: '%s'\n", str); |
#endif | | #endif |
| | /* |
| | * remove trailing spaces |
| | */ |
| | cp = str+strlen(str)-1; |
| | while ( (cp>=str) && (*cp==' ')){ |
| | *cp='\0'; |
| | cp--; |
| | } |
/* | | /* |
* No arguments? | | * No arguments? |
*/ | | */ |
| | |
int i; | | int i; |
/* if it's a keybinding command, ignore semicolons */ | | /* if it's a keybinding command, ignore semicolons */ |
if(strstr(str,"bind")) return parse_string(op,str); | | if(strstr(str,"bind")) return parse_string(op,str); |
| | printf("parsin command '%s'\n",str); |
/* If on a socket, you can not do complex commands. */ | | /* If on a socket, you can not do complex commands. */ |
if(op && (tmp=strchr(str,';'))!=NULL) /* we've found a ';' do the 1st and recurse */ | | if(op && (tmp=strchr(str,';'))!=NULL) /* we've found a ';' do the 1st and recurse */ |
{ | | { |