|
The pointer you pass represents the beginning of a string. There is no requirement that it be at the beginning of a defined array of char, only that the data from that point onwards qualifies as a string (zero or more char followed by a null terminator).
The pointer returned represents the beginning of the substring. If you increment the pointer from that position, that particular substring can no longer be found; only the characters beyond that position, up to the terminator, are subsequently searched.
|