Using strtok_r for the string parsing.