postgresql/src/include
Tom Lane 4136408902 Fix an oversight in the support for storing/retrieving "minimal tuples" in
TupleTableSlots.  We have functions for retrieving a minimal tuple from a slot
after storing a regular tuple in it, or vice versa; but these were implemented
by converting the internal storage from one format to the other.  The problem
with that is it invalidates any pass-by-reference Datums that were already
fetched from the slot, since they'll be pointing into the just-freed version
of the tuple.  The known problem cases involve fetching both a whole-row
variable and a pass-by-reference value from a slot that is fed from a
tuplestore or tuplesort object.  The added regression tests illustrate some
simple cases, but there may be other failure scenarios traceable to the same
bug.  Note that the added tests probably only fail on unpatched code if it's
built with --enable-cassert; otherwise the bug leads to fetching from freed
memory, which will not have been overwritten without additional conditions.

Fix by allowing a slot to contain both formats simultaneously; which turns out
not to complicate the logic much at all, if anything it seems less contorted
than before.

Back-patch to 8.2, where minimal tuples were introduced.
2009-03-30 04:09:18 +00:00
..
access Install a search tree depth limit in GIN bulk-insert operations, to prevent 2009-03-24 22:06:32 +00:00
bootstrap pgindent run for 8.2. 2006-10-04 00:30:14 +00:00
catalog Repair a longstanding bug in CLUSTER and the rewriting variants of ALTER 2009-02-24 01:39:01 +00:00
commands Back-patch the 8.3 fix that prohibits TRUNCATE, CLUSTER, and REINDEX when the 2008-05-27 21:13:25 +00:00
executor Fix an oversight in the support for storing/retrieving "minimal tuples" in 2009-03-30 04:09:18 +00:00
lib Update copyright for 2006. Update scripts. 2006-03-05 15:59:11 +00:00
libpq When we are in error recursion trouble, arrange to suppress translation and 2009-03-02 21:18:57 +00:00
mb Replace argument-checking Asserts with regular test-and-elog checks in all 2009-01-29 19:24:19 +00:00
nodes Fix an oversight in the code that makes transitive-equality deductions from 2008-12-01 21:06:31 +00:00
optimizer Get rid of adjust_appendrel_attr_needed(), which has been broken ever since 2008-11-11 18:13:54 +00:00
parser Fix failure to ensure that a snapshot is available to datatype input functions 2008-12-13 02:00:53 +00:00
port Back-patch mingw configure-check for gettimeofday so that 8.2 can 2007-11-29 16:44:26 +00:00
postmaster Implement a chunking protocol for writes to the syslogger pipe, with messages 2007-06-14 01:49:39 +00:00
regex Fix assorted security-grade bugs in the regex engine. All of these problems 2008-01-03 20:48:49 +00:00
rewrite Fix pull_up_simple_union_all to copy all rtable entries from child subquery to 2008-08-14 20:32:11 +00:00
storage Widen the nLocks counts in local lock tables from int to int64. This 2008-09-16 01:56:43 +00:00
tcop On platforms that have getrlimit(RLIMIT_STACK), use it to ensure that 2006-10-07 19:25:29 +00:00
utils Install a more robust solution for the problem of infinite error-processing 2008-10-27 19:37:36 +00:00
c.h Allow Borland CC to compile libpq and psql. 2007-01-11 02:40:12 +00:00
fmgr.h pgindent run for 8.2. 2006-10-04 00:30:14 +00:00
funcapi.h pgindent run for 8.2. 2006-10-04 00:30:14 +00:00
getaddrinfo.h pgindent run for 8.2. 2006-10-04 00:30:14 +00:00
getopt_long.h Update copyright for 2006. Update scripts. 2006-03-05 15:59:11 +00:00
Makefile Allow installation into directories containing spaces in the name. 2005-12-09 21:19:36 +00:00
miscadmin.h Make standard maintenance operations (including VACUUM, ANALYZE, REINDEX, 2008-01-03 21:23:45 +00:00
pg_config.h.in Back-patch mingw configure-check for gettimeofday so that 8.2 can 2007-11-29 16:44:26 +00:00
pg_config.h.win32 tag 8.2.13 2009-03-13 02:16:43 +00:00
pg_config_manual.h Add built-in userlock manipulation functions to replace the former 2006-09-18 22:40:40 +00:00
pg_trace.h pgindent run for 8.2. 2006-10-04 00:30:14 +00:00
pgstat.h Remove the pgstat_drop_relation() call from smgr_internal_unlink(), because 2007-07-08 22:23:25 +00:00
pgtime.h Fix up timetz input so that a date is required only when the specified 2006-10-18 16:43:14 +00:00
port.h Avoid using unnecessary pgwin32_safestat in libpq. 2008-04-16 14:24:38 +00:00
postgres.h Adjust DatumGetBool macro so that it isn't fooled by garbage in the Datum 2008-03-25 19:31:31 +00:00
postgres_ext.h Pgindent run for 8.0. 2004-08-29 05:07:03 +00:00
postgres_fe.h Update copyright for 2006. Update scripts. 2006-03-05 15:59:11 +00:00
rusagestub.h Update copyright for 2006. Update scripts. 2006-03-05 15:59:11 +00:00