char *token;
char *state;
for (token = strtok_r(input, "&", &state);
token != NULL;
token = strtok_r(NULL, "&", &state))
{
...
}
More Related Contents:
- How does strtok() split the string into tokens in C?
- Split string with delimiters in C
- How can I concatenate twice with the C preprocessor and expand a macro as in “arg ## _ ## MACRO”?
- Creating C macro with ## and __LINE__ (token concatenation with positioning macro)
- Parse (split) a string in C++ using string delimiter (standard C++)
- Nested strtok function problem in C [duplicate]
- Split string into tokens and save them in an array
- What is the size of an enum in C?
- Including one C source file in another?
- What’s the difference between a VLA and dynamic memory allocation via malloc?
- What does dot (.) mean in a struct initializer?
- Can gcc output C code after preprocessing?
- How to set include path in xcode project
- Is it faster to count down than it is to count up?
- difference between %ms and %s scanf
- Can I rely on malloc returning NULL?
- What is the difference between using _exit() & exit() in a conventional Linux fork-exec?
- How can you flush a write using a file descriptor?
- WinVerifyTrust to check for a specific signature?
- integer size in c depends on what?
- MPI partition matrix into blocks
- Can I make gcc tell me when a calculation results in NaN or inf at runtime?
- size of int variable
- How to optimize these loops (with compiler optimization disabled)?
- Pseudo-generics in C
- Why does a program accessing illegal pointer to pointer not crash?
- static function in C
- C programming in Visual Studio
- Reopen a file descriptor with another access?
- Iterating over same type struct members in C