From e781fb26fdd422ea72c3a0eeba817e4faa5f663b Mon Sep 17 00:00:00 2001 From: Ben Burwell Date: Wed, 1 Apr 2015 20:22:48 -0400 Subject: as of 2013-10-17 --- comhan.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'comhan.c') diff --git a/comhan.c b/comhan.c index febb503..21a3448 100644 --- a/comhan.c +++ b/comhan.c @@ -46,10 +46,10 @@ char *aliases[] = {" ", " ", " ", " ", */ void comhan() { - char *args[5]; + static char *args[7]; //one more than expected number of arguments int argc; int cmd_num; - char buffer[BUF_SIZE]; + static char buffer[BUF_SIZE]; int do_stop = 0; do { @@ -102,7 +102,7 @@ int get_cmd(char cmd[]){ int set_args(char buffer[], char *args[]) { /* use string tok to set the contents of args from buffer and return the number of args (will go into argc) */ - char separators[4] = " =/"; //Characters that separate tokens + char separators[5] = " =/,"; //Characters that separate tokens int i = 0; //loop control args[i] = strtok(buffer, separators); //Get first token @@ -178,7 +178,6 @@ int cmd_stop(){ printf("**COMHAN execution complete **\n"); return 1; } else { - printf("Okay! \n"); return 0; } } @@ -413,7 +412,8 @@ void cmd_allocate(char *args[]) { return; } - result = build_pcb(new, args[1], type, state, suspend, priority); + result = build_pcb(new, args[1], type, state, suspend, priority, + NULL, NULL, NULL, NULL); switch (result) { case 1: break; -- cgit v1.2.3