Re: Bug in UTF8-Validation Code?
Tom Lane <tgl@sss.pgh.pa.us>
From: Tom Lane <tgl@sss.pgh.pa.us>
To: Mark Dilger <pgsql@markdilger.com>
Cc: Albe Laurenz <all@adv.magwien.gv.at>, pgsql-hackers@postgresql.org
Date: 2007-04-04T17:01:18Z
Lists: pgsql-hackers
Mark Dilger <pgsql@markdilger.com> writes: > Albe Laurenz wrote: >> 0x00 is a valid UNICODE code point and also a valid UTF-8 character! > It's not my code that rejects this. I'm passing the resultant string to > the pg_verify_mbstr(...) function and it is rejecting a null. I could > change that, of course, but if other parts of the system found it > reasonable to reject null, why should chr() be different? chr() really should reject that if it's going to do any error checking at all, because text operations tend to misbehave on embedded nulls. regards, tom lane