2479. Unclear how wbuffer_convert uses cvtstate

Section: D.18.2 [depr.conversions.buffer] Status: New Submitter: Jonathan Wakely Opened: 2015-03-04 Last modified: 2017-05-13

Priority: 4

View other active issues in [depr.conversions.buffer].

View all other issues in [depr.conversions.buffer].

View all issues with New status.


How does wbuffer_convert use the cvtstate member?

Is the same conversion state object used for converting both the get and put areas? That means a read which runs out of bytes halfway through a multibyte character will leave some shift state in cvtstate, which would then be used by a following write, even though the shift state of the get area is unrelated to the put area.

Proposed resolution: