7.24.6.3 Restartable multibyte/wide character conversion functions

1

These functions differ from the corresponding multibyte character functions of 7.20.7 (mblen, mbtowc, and wctomb) in that they have an extra parameter, ps, of type pointer to mbstate_t that points to an object that can completely describe the current conversion state of the associated multibyte character sequence. If ps is a null pointer, each function uses its own internal mbstate_t object instead, which is initialized at program startup to the initial conversion state. The implementation behaves as if no library function calls these functions with a null pointer for ps.

2

Also unlike their corresponding functions, the return value does not represent whether the encoding is state-dependent.