Copy results of strtok to 2 strings in C
- by Mr. Man
Ok, so I have the code
char *token;
char *delimiter = " ";
token = strtok(command, delimiter);
strcpy(command, token);
token = strtok(NULL, delimiter);
strcpy(arguments, token);
and it gives me EXC_BAD_ACCESS when i run it, and yes, command and arguments are already defined.