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 th
strtok manipulates the string you pass in and returns a pointer to it, so no memory is allocated.
Please consider using strsep or at least strtok_r to save you some headaches later.