From: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
---|---|
To: | pgsql-committers(at)lists(dot)postgresql(dot)org |
Subject: | pgsql: Fix oversight in commit 0dca5d68d. |
Date: | 2025-04-03 20:03:21 |
Message-ID: | E1u0QmX-002Vik-0m@gemulon.postgresql.org |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-committers |
Fix oversight in commit 0dca5d68d.
As coded, fmgr_sql() would get an assertion failure for a SQL function
that has an empty body and is declared to return some type other than
VOID. Typically you'd never get that far because fmgr_sql_validator()
would reject such a definition (I suspect that's how come I managed to
miss the bug). But if check_function_bodies is off or the function is
polymorphic, the validation check wouldn't get made.
Reported-by: Alexander Lakhin <exclusion(at)gmail(dot)com>
Author: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Discussion: https://postgr.es/m/0fde377a-3870-4d18-946a-ce008ee5bb88@gmail.com
Branch
------
master
Details
-------
https://git.postgresql.org/pg/commitdiff/dbd437e670b88ca67f6b2477e853412a0e82a8cc
Modified Files
--------------
src/backend/executor/functions.c | 15 ++++++++++++++-
src/test/regress/expected/create_function_sql.out | 17 ++++++++++++++++-
src/test/regress/sql/create_function_sql.sql | 10 ++++++++++
3 files changed, 40 insertions(+), 2 deletions(-)
From | Date | Subject | |
---|---|---|---|
Next Message | Melanie Plageman | 2025-04-03 22:24:49 | pgsql: Remove misleading read stream asserts in a few users |
Previous Message | Daniel Gustafsson | 2025-04-03 19:14:02 | pgsql: oauth: Fix build on platforms without epoll/kqueue |