Skip to content

tests: Ensure saveptr is NULL before first call to strtok_r()

Simon McVittie requested to merge wip/smcv/strtok-r into master

The standards-conformant behaviour is that the contents of saveptr are ignored when the first argument is non-NULL, but the man page notes that some older implementations required saveptr to be NULL in that situation, and the gcc 4.8 provided by the Steam Runtime warns about this.


Continuing my adventures in retrocomputing...

/cc @walters @wjt

Merge request reports

Loading