Re: Support LIKE with nondeterministic collations
Peter Eisentraut <peter@eisentraut.org>
From: Peter Eisentraut <peter@eisentraut.org>
To: Jacob Champion <jacob.champion@enterprisedb.com>
Cc: pgsql-hackers <pgsql-hackers@postgresql.org>,
Daniel Verite <daniel@manitou-mail.org>,
Paul A Jungwirth <pj@illuminatedcomputing.com>
Date: 2024-11-04T08:26:37Z
Lists: pgsql-hackers
Commits
Same data as JSON:
GET /api/v1/messages/:b64id/commits
the thread's linked commits as JSON, with link sources.
API reference →
-
Support LIKE with nondeterministic collations
- 85b7efa1cdd6 18.0 landed
Attachments
- v6-0001-Support-LIKE-with-nondeterministic-collations.patch (text/plain) patch v6-0001
On 29.10.24 18:15, Jacob Champion wrote:
> libfuzzer is unhappy about the following code in MatchText:
>
>> + while (p1len > 0)
>> + {
>> + if (*p1 == '\\')
>> + {
>> + found_escape = true;
>> + NextByte(p1, p1len);
>> + }
>> + else if (*p1 == '_' || *p1 == '%')
>> + break;
>> + NextByte(p1, p1len);
>> + }
>
> If the pattern ends with a backslash, we'll call NextByte() twice,
> p1len will wrap around to INT_MAX, and we'll walk off the end of the
> buffer. (I fixed it locally by duplicating the ERROR case that's
> directly above this.)
Thanks. Here is an updated patch with that fixed.