Defect Report #213

Previous Defect Report < - > Next Defect Report

Submitter: Clive Feather
Submission Date: 1999-10-20
Reference Document: ISO/IEC WG14 N900
Version: 1.2
Date: 2000-11-02 13:50:06
Subject: Lacuna in mbrtowc

The description of the result of mbrtowc uses the term "positive" to distinguish one case from others. Unfortunately some of the other cases are also positive, because they are negative numbers cast to the (unsigned) type size_t.

The actual return value in this case is always between 1 and the value of the parameter n (inclusive): positive if the next n or fewer bytes complete a valid multibyte character (which is the value stored); the value returned is the number of bytes that complete the multibyte character.

Technical Corrigendum
In paragraph 4, change the label of the case "positive" to "between 1 and n inclusive".

Previous Defect Report < - > Next Defect Report