Robert Haas <robertmhaas@gmail.com> writes:
> On Fri, Aug 13, 2010 at 1:50 PM, Tom Lane <tgl@sss.pgh.pa.us> wrote:
>> AFAICS the version in mbprint.c is flat out wrong, and the only reason
>> nobody's noticed is that it should never get passed a more-than-4-byte
>> sequence anyway.
> Should we fix it, then, and if so how far should we go back?
Yes, I'd vote for back-patching, at least to all versions in which the
wchar.c version looks like that.
regards, tom lane