pgsql: Prevent inlining a SQL function with multiple OUT parameters.

Поиск
Список
Период
Сортировка
От Tom Lane
Тема pgsql: Prevent inlining a SQL function with multiple OUT parameters.
Дата
Msg-id E1PNfeB-0004LW-AV@gemulon.postgresql.org
обсуждение исходный текст
Список pgsql-committers
Prevent inlining a SQL function with multiple OUT parameters.

There were corner cases in which the planner would attempt to inline such
a function, which would result in a failure at runtime due to loss of
information about exactly what the result record type is.  Fix by disabling
inlining when the function's recorded result type is RECORD.  There might
be some sub-cases where inlining could still be allowed, but this is a
simple and backpatchable fix, so leave refinements for another day.
Per bug #5777 from Nate Carson.

Back-patch to all supported branches.  8.1 happens to avoid a core-dump
here, but it still does the wrong thing.

Branch
------
REL8_1_STABLE

Details
-------
http://git.postgresql.org/gitweb?p=postgresql.git;a=commitdiff;h=8a6eb2ee9895b88311d01fd0d54fb380304d3df6

Modified Files
--------------
src/backend/executor/functions.c         |    5 +++++
src/backend/optimizer/util/clauses.c     |    5 +++++
src/test/regress/expected/rangefuncs.out |   20 ++++++++++++++++++++
src/test/regress/sql/rangefuncs.sql      |   19 +++++++++++++++++++
4 files changed, 49 insertions(+), 0 deletions(-)


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

Предыдущее
От: itagaki@pgfoundry.org (User Itagaki)
Дата:
Сообщение: orafce - orafce: work around for 9.1.
Следующее
От: Tom Lane
Дата:
Сообщение: pgsql: Prevent inlining a SQL function with multiple OUT parameters.