Conversion continues up to and including a terminating null wide-character, which is also stored.
Each conversion takes place as if by a call to the wcrtomb function. If conversion stopped due to reaching a terminating null wide-character, the resulting state described is the initial conversion state. The implementation will behave as if no function defined in this specification calls wcsrtombs . If conversion stops because a code is reached that does not correspond to a valid character, an encoding error occurs. A wide-character code does not correspond to a valid character.