From: Tatsuo Ishii <ishii@postgresql.org>
To: pgsql-committers@lists.postgresql.org
Subject: pgsql: Use ereport rather than elog in WinCheckAndInitializeNullTreatme
Date: Tue, 14 Oct 2025 10:19:38 +0000
Message-ID: <E1v8c82-001dih-0t@gemulon.postgresql.org> (raw)
Use ereport rather than elog in WinCheckAndInitializeNullTreatment.
Previously WinCheckAndInitializeNullTreatment() used elog() to emit an
error message. ereport() should be used instead because it's a
user-facing error. Also use existing get_func_name() to get a
function's name, rather than own implementation.
Moreover add an assertion to validate winobj parameter, just like
other window function API.
Reported-by: Tom Lane <tgl@sss.pgh.pa.us>
Author: Tatsuo Ishii <ishii@postgresql.org>
Reviewed-by: Chao Li <lic@highgo.com>
Discussion: https://postgr.es/m/2952409.1760023154%40sss.pgh.pa.us
Branch
------
master
Details
-------
https://git.postgresql.org/pg/commitdiff/5f3808646f67260d5dc0d95f2602886da5cf5c52
Modified Files
--------------
src/backend/executor/nodeWindowAgg.c | 20 ++++++++------------
1 file changed, 8 insertions(+), 12 deletions(-)
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: pgsql-committers@postgresql.org
Cc: ishii@postgresql.org, pgsql-committers@lists.postgresql.org
Subject: Re: pgsql: Use ereport rather than elog in WinCheckAndInitializeNullTreatme
In-Reply-To: <E1v8c82-001dih-0t@gemulon.postgresql.org>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox