From: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
---|---|
To: | pgsql-committers(at)postgresql(dot)org |
Subject: | pgsql: Guard against null arguments in binary_upgrade_create_empty_exte |
Date: | 2016-01-03 21:26:44 |
Message-ID: | E1aFqAm-0001Ju-LV@gemulon.postgresql.org |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-committers |
Guard against null arguments in binary_upgrade_create_empty_extension().
The CHECK_IS_BINARY_UPGRADE macro is not sufficient security protection
if we're going to dereference pass-by-reference arguments before it.
But in any case we really need to explicitly check PG_ARGISNULL for all
the arguments of a non-strict function, not only the ones we expect null
values for.
Oversight in commits 30982be4e5019684e1772dd9170aaa53f5a8e894 and
f92fc4c95ddcc25978354a8248d3df22269201bc. Found by Andreas Seltenreich.
(The other usages in pg_upgrade_support.c seem safe.)
Branch
------
master
Details
-------
http://git.postgresql.org/pg/commitdiff/939d10cd8711fdeb7f0ff62c9c6b08e3eddbba3e
Modified Files
--------------
src/backend/utils/adt/pg_upgrade_support.c | 20 ++++++++++++++++----
1 file changed, 16 insertions(+), 4 deletions(-)
From | Date | Subject | |
---|---|---|---|
Next Message | Tom Lane | 2016-01-04 01:04:19 | pgsql: Do some copy-editing on the docs for row-level security. |
Previous Message | Tom Lane | 2016-01-03 21:03:54 | pgsql: Do some copy-editing on the docs for replication origins. |