This is std::string. After the function call is completed, tmpString is destructed and the allocated data will be deleted. Since you want to use string, token_node should also use std::string, or it is best to use a heap-allocated char array directly.
This is std::string. After the function call is completed, tmpString is destructed and the allocated data will be deleted.
Since you want to use string, token_node should also use std::string, or it is best to use a heap-allocated char array directly.