low_str_strtok Find the next token in a string.
l_text low_str_strtok ( l_text strToken, cl_text strDelimit );
Return Value
All of these functions return a pointer to the next token found in @strToken. They return NULL when no more tokens are found. Each call modifies @strToken by substituting a NULL character for each delimiter that is encountered.
Parameters
strToken
String containing token(s)
strDelimit
Set of delimiter characters
Remarks
The low_str_strtok function finds the next token in @strToken. The set of characters in @strDelimit specifies possible delimiters of the token to be found in @strToken on the current call.
On the first call to low_str_strtok, the function skips leading delimiters and returns a pointer to the first token in @strToken, terminating the token with a null character. More tokens can be broken out of the remainder of @strToken by a series of calls to low_str_strtok. Each call to low_str_strtok modifies @strToken by inserting a null character after the token returned by that call. To read the next token from @strToken, call low_str_strtok with a NULL value for the @strToken argument. The NULL @strToken argument causes strtok to search for the next token in the modified @strToken. The @strDelimit argument can take any value from one call to the next so that the set of delimiters may vary.
Warning Each of these functions uses a static variable for parsing the string into tokens. If multiple or simultaneous calls are made to the same function, a high potential for data corruption and inaccurate results exists. Therefore, do not attempt to call the same function simultaneously for different strings and be aware of calling one of these function from within a loop where another routine may be called that uses the same function. However, calling this function simultaneously from multiple threads does not have undesirable effects.