Do I need to free the strtok resulting string?
问题 Or rather, how does strtok produce the string to which it's return value points? Does it allocate memory dynamically? I am asking because I am not sure if I need to free the token in the following code: The STANDARD_INPUT variables is for exit procedure in case I run out of memory for allocation and the string is the tested subject. int ValidTotal(STANDARD_INPUT, char *str) { char *cutout = NULL, *temp, delim = '#'; int i = 0; //Checks the number of ladders in a string, 3 is the required