libcpp/charset: close out shift states
Mon Dec 10 18:53:00 GMT 2007
>>>>> "DJ" == DJ Delorie <firstname.lastname@example.org> writes:
DJ> + /* Close out any shift states, returning to the initial state. */
DJ> + if (iconv (cd, 0, 0, &outbuf, &outbytesleft) == (size_t)-1)
DJ> + return false;
What if this new iconv call returns -1 with errno==E2BIG? In this
case, we will return false -- but I think what we really want to do is
resize the output buffer and try again.
I think with a change to fix this problem, this is ok.
More information about the Gcc-patches