mirror of
https://github.com/boostorg/serialization.git
synced 2026-02-22 15:42:30 +00:00
The mbtowc(), wctomb() and mblen() functions are not supposed to be thread-safe, as they have to keep parsing state in a global variable. The mbrtowc(), wcrtomb() and mbrlen() functions should be used instead. This change also simplifies how wchar_from_mb<Base>::drain() works. There is no need to first iterate over the input using mblen(). mbrtowc() can store the partially parsed multibyte character in its mbstate_t.