pgsql: Fix SIGSEGV in pruning for ScalarArrayOp with constant-null arra

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: pgsql-committers(at)lists(dot)postgresql(dot)org
Subject: pgsql: Fix SIGSEGV in pruning for ScalarArrayOp with constant-null arra
Date: 2019-08-09 17:20:43
Message-ID: E1hw8ZH-0007Bf-45@gemulon.postgresql.org
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-committers

Fix SIGSEGV in pruning for ScalarArrayOp with constant-null array.

Not much to be said here: commit 9fdb675fc should have checked
constisnull, didn't.

Per report from Piotr Włodarczyk. Back-patch to v11 where
bug was introduced.

Discussion: https://postgr.es/m/CAP-dhMr+vRpwizEYjUjsiZ1vwqpohTm+3Pbdt6Pr7FEgPq9R0Q@mail.gmail.com

Branch
------
REL_11_STABLE

Details
-------
https://git.postgresql.org/pg/commitdiff/2f729d83226705d1149419a2aef7c1678fe641ec

Modified Files
--------------
src/backend/partitioning/partprune.c | 7 ++-
src/test/regress/expected/partition_prune.out | 68 +++++++++++++++++++++++++++
src/test/regress/sql/partition_prune.sql | 10 ++++
3 files changed, 84 insertions(+), 1 deletion(-)

Browse pgsql-committers by date

  From Date Subject
Next Message Peter Geoghegan 2019-08-10 00:08:39 pgsql: Rename tuplesort.c's SortTuple.tupindex field.
Previous Message Tom Lane 2019-08-09 16:33:49 pgsql: Cosmetic improvements in setup of planner's per-RTE arrays.