Re: BUG #5566: High levels of savepoint nesting trigger stack overflow in AssignTransactionId

Поиск
Список
Период
Сортировка
От Andres Freund
Тема Re: BUG #5566: High levels of savepoint nesting trigger stack overflow in AssignTransactionId
Дата
Msg-id 201007191758.06834.andres@anarazel.de
обсуждение исходный текст
Ответ на BUG #5566: High levels of savepoint nesting trigger stack overflow in AssignTransactionId  ("Hans van Kranenburg" <hans.van.kranenburg@mendix.com>)
Ответы Re: [PATCH] BUG #5566: High levels of savepoint nesting trigger stack overflow in AssignTransactionId  (Andres Freund <andres@anarazel.de>)
Re: BUG #5566: High levels of savepoint nesting trigger stack overflow in AssignTransactionId  (Alvaro Herrera <alvherre@commandprompt.com>)
Список pgsql-bugs
On Monday 19 July 2010 17:26:25 Hans van Kranenburg wrote:
> When issuing an update statement in a transaction with ~30800 levels of
> savepoint nesting, (which is insane, but possible), postgresql segfaults
> due to a stack overflow in the AssignTransactionId function, which
> recursively assign transaction ids to parent transactions.
It seems easy enough to throw a check_stack_depth() in there - survives make
check here.

It would be nice to check this earlier on though - or simply impose a
artificial limit of nested transactions. I severely doubt that there are non-
bug situations with a nesting of above 1k (so maybe set the limit to 3k).

Thats independent from checking stack depth there though - it sounds possible
to get there after an already relatively deep stack usage (deeply nested
functions or such).

Andres

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

Предыдущее
От: "Hans van Kranenburg"
Дата:
Сообщение: BUG #5566: High levels of savepoint nesting trigger stack overflow in AssignTransactionId
Следующее
От: Andres Freund
Дата:
Сообщение: Re: [PATCH] BUG #5566: High levels of savepoint nesting trigger stack overflow in AssignTransactionId