postgresql/src
Tom Lane 78a030a441 Fix confusion about number of subplans in partitioned INSERT setup.
ExecInitModifyTable() thought there was a plan per partition, but no,
there's only one.  The problem had escaped detection so far because there
would only be visible misbehavior if there were a SubPlan (not an InitPlan)
in the quals being duplicated for each partition.  However, valgrind
detected a bogus memory access in test cases added by commit 4f7a95be2,
and investigation of that led to discovery of the bug.  The additional
test case added here crashes without the patch.

Patch by Amit Langote, test case by me.

Discussion: https://postgr.es/m/10974.1497227727@sss.pgh.pa.us
2017-06-12 23:29:53 -04:00
..
backend Fix confusion about number of subplans in partitioned INSERT setup. 2017-06-12 23:29:53 -04:00
bin pg_dump: Fix harmless type mixup 2017-06-12 23:06:38 -04:00
common Post-PG 10 beta1 pgperltidy run 2017-05-17 19:01:23 -04:00
fe_utils Allow psql variable substitution to occur in backtick command strings. 2017-04-01 21:44:54 -04:00
include Use standard interrupt handling in logical replication launcher. 2017-06-08 15:38:50 -07:00
interfaces Silence warning about uninitialized 'ret' variable on some compilers. 2017-06-09 21:50:35 +03:00
makefiles Always use -fPIC, not -fpic, when building shared libraries with gcc. 2017-06-01 13:32:55 -04:00
pl Update expected file 2017-05-25 14:41:43 -04:00
port Post-PG 10 beta1 pgindent run 2017-05-17 16:31:56 -04:00
template Remove "sco" and "unixware" ports. 2016-10-11 11:26:04 -04:00
test Fix confusion about number of subplans in partitioned INSERT setup. 2017-06-12 23:29:53 -04:00
timezone Guard against null t->tm_zone in strftime.c. 2017-05-07 12:33:12 -04:00
tools Add MSVC build system support for ICU 2017-06-12 11:05:20 -04:00
tutorial Recommend wrappers of PG_DETOAST_DATUM_PACKED(). 2017-03-12 19:35:33 -04:00
.gitignore
DEVELOPERS
Makefile Remove redundant coverage target 2017-02-17 08:56:57 -05:00
Makefile.global.in Add ICU_CFLAGS to global CPPFLAGS 2017-06-12 15:57:22 -04:00
Makefile.shlib Remove support for bcc and msvc standalone libpq builds 2017-04-11 15:22:21 +02:00
nls-global.mk nls-global.mk: search build dir for source files, too 2016-06-07 18:55:18 -04:00