Re: BUG #18705: Segmentation fault when create brin index on user-defined type.

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: BUG #18705: Segmentation fault when create brin index on user-defined type.
Дата
Msg-id 2448486.1731685634@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: BUG #18705: Segmentation fault when create brin index on user-defined type.  (Tomas Vondra <tomas@vondra.me>)
Список pgsql-bugs
Tomas Vondra <tomas@vondra.me> writes:
> On 11/15/24 07:17, Tender Wang wrote:
>> Can we report errors not crash if users pass an unexpected function?

Read up on the halting problem.

> I think it might be improved to do some checks, yes. The CREATE OPERATOR
> CLASS should be able to signatures of the functions - it's AM-specific,
> and there's a limit how much can be checked. For example these functions
> have "internal" arguments, which can be an arbitrary pointer.

We already have amvalidate, which would certainly have caught anything
as egregiously wrong as this example.  I do not remember why that's
not a forced step of CREATE OPERATOR CLASS, but I'm sure there
was a good reason for making it separate.

            regards, tom lane



В списке pgsql-bugs по дате отправления: