postgresql/src/include/utils
Tom Lane 6919b7e329 Fix failure to ignore leftover temp tables after a server crash.
During crash recovery, we remove disk files belonging to temporary tables,
but the system catalog entries for such tables are intentionally not
cleaned up right away.  Instead, the first backend that uses a temp schema
is expected to clean out any leftover objects therein.  This approach
requires that we be careful to ignore leftover temp tables (since any
actual access attempt would fail), *even if their BackendId matches our
session*, if we have not yet established use of the session's corresponding
temp schema.  That worked fine in the past, but was broken by commit
debcec7dc3 which incorrectly removed the
rd_islocaltemp relcache flag.  Put it back, and undo various changes
that substituted tests like "rel->rd_backend == MyBackendId" for use
of a state-aware flag.  Per trouble report from Heikki Linnakangas.

Back-patch to 9.1 where the erroneous change was made.  In the back
branches, be careful to add rd_islocaltemp in a spot in the struct that
was alignment padding before, so as not to break existing add-on code.
2012-12-17 20:15:32 -05:00
..
.gitignore Avoid maintaining three separate copies of the error codes list. 2011-02-03 22:32:49 -05:00
acl.h Syntax support and documentation for event triggers. 2012-07-18 10:16:16 -04:00
array.h Add array_remove() and array_replace() functions. 2012-07-11 13:59:35 -04:00
ascii.h Update copyright notices for year 2012. 2012-01-01 18:01:58 -05:00
attoptcache.h Update copyright notices for year 2012. 2012-01-01 18:01:58 -05:00
builtins.h Support automatically-updatable views. 2012-12-08 18:26:21 -05:00
bytea.h Update copyright notices for year 2012. 2012-01-01 18:01:58 -05:00
cash.h Add casts from int4 and int8 to numeric. 2011-04-05 09:35:43 -04:00
catcache.h Remove unnecessary "head" arguments from some dlist/slist functions. 2012-10-18 19:04:20 -04:00
combocid.h Update copyright notices for year 2012. 2012-01-01 18:01:58 -05:00
date.h Add transform functions for various temporal typmod coercisions. 2012-02-08 09:33:37 -05:00
datetime.h Mark DateTimeParseError() noreturn 2012-08-21 23:32:58 -04:00
datum.h Update copyright notices for year 2012. 2012-01-01 18:01:58 -05:00
dynahash.h Update copyright notices for year 2012. 2012-01-01 18:01:58 -05:00
dynamic_loader.h Update copyright notices for year 2012. 2012-01-01 18:01:58 -05:00
elog.h Use correct text domain for translating errcontext() messages. 2012-11-12 17:07:29 +02:00
evtcache.h Make new event trigger facility actually do something. 2012-07-20 11:39:01 -04:00
fmgrtab.h Update copyright notices for year 2012. 2012-01-01 18:01:58 -05:00
formatting.h Update copyright notices for year 2012. 2012-01-01 18:01:58 -05:00
geo_decls.h Update copyright notices for year 2012. 2012-01-01 18:01:58 -05:00
guc.h Add support for include_dir in config file. 2012-09-24 18:07:53 +03:00
guc_tables.h Run pgindent on 9.2 source tree in preparation for first 9.3 2012-06-10 15:20:04 -04:00
help_config.h Unify calling conventions for postgres/postmaster sub-main functions 2012-06-25 21:30:12 +03:00
hsearch.h Update copyright notices for year 2012. 2012-01-01 18:01:58 -05:00
inet.h Update copyright notices for year 2012. 2012-01-01 18:01:58 -05:00
int8.h Update copyright notices for year 2012. 2012-01-01 18:01:58 -05:00
inval.h Split tuple struct defs from htup.h to htup_details.h 2012-08-30 16:52:35 -04:00
json.h Run pgindent on 9.2 source tree in preparation for first 9.3 2012-06-10 15:20:04 -04:00
logtape.h Update copyright notices for year 2012. 2012-01-01 18:01:58 -05:00
lsyscache.h Split tuple struct defs from htup.h to htup_details.h 2012-08-30 16:52:35 -04:00
memutils.h Run pgindent on 9.2 source tree in preparation for first 9.3 2012-06-10 15:20:04 -04:00
nabstime.h Update copyright notices for year 2012. 2012-01-01 18:01:58 -05:00
numeric.h Update copyright notices for year 2012. 2012-01-01 18:01:58 -05:00
palloc.h Rename USE_INLINE to PG_USE_INLINE 2012-10-09 11:17:33 -03:00
pg_crc.h Add const qualifiers where they are accidentally cast away 2012-02-28 12:42:08 +02:00
pg_crc_tables.h Run pgindent on 9.2 source tree in preparation for first 9.3 2012-06-10 15:20:04 -04:00
pg_locale.h Replace empty locale name with implied value in CREATE DATABASE and initdb. 2012-03-25 21:47:22 -04:00
pg_lzcompress.h Remove cvs keywords from all files. 2010-09-20 22:08:53 +02:00
pg_rusage.h Update copyright notices for year 2012. 2012-01-01 18:01:58 -05:00
plancache.h Run pgindent on 9.2 source tree in preparation for first 9.3 2012-06-10 15:20:04 -04:00
portal.h COPY FREEZE and mark committed on fresh tables. 2012-12-01 12:54:20 +00:00
ps_status.h Remove cvs keywords from all files. 2010-09-20 22:08:53 +02:00
rangetypes.h Collect and use histograms of lower and upper bounds for range types. 2012-08-27 15:58:46 +03:00
rbtree.h Update copyright notices for year 2012. 2012-01-01 18:01:58 -05:00
rel.h Fix failure to ignore leftover temp tables after a server crash. 2012-12-17 20:15:32 -05:00
relcache.h Remove RELKIND_UNCATALOGED. 2012-06-14 09:47:30 -04:00
relmapper.h Update copyright notices for year 2012. 2012-01-01 18:01:58 -05:00
reltrigger.h Update copyright notices for year 2012. 2012-01-01 18:01:58 -05:00
resowner.h Split resowner.h 2012-08-28 18:02:07 -04:00
resowner_private.h Split resowner.h 2012-08-28 18:02:07 -04:00
selfuncs.h Refactor pattern_fixed_prefix() to avoid dealing in incomplete patterns. 2012-07-09 23:22:55 -04:00
snapmgr.h COPY FREEZE and mark committed on fresh tables. 2012-12-01 12:54:20 +00:00
snapshot.h Slightly reorganize struct SnapshotData. 2012-01-06 22:56:00 -05:00
sortsupport.h Rename USE_INLINE to PG_USE_INLINE 2012-10-09 11:17:33 -03:00
spccache.h Update copyright notices for year 2012. 2012-01-01 18:01:58 -05:00
syscache.h remove catcache.h from syscache.h 2012-08-28 18:36:39 -04:00
timeout.h Introduce timeout handling framework 2012-07-16 22:55:33 -04:00
timestamp.h Make the streaming replication protocol messages architecture-independent. 2012-11-07 19:09:13 +02:00
tqual.h Run pgindent on 9.2 source tree in preparation for first 9.3 2012-06-10 15:20:04 -04:00
tuplesort.h Update copyright notices for year 2012. 2012-01-01 18:01:58 -05:00
tuplestore.h Update copyright notices for year 2012. 2012-01-01 18:01:58 -05:00
typcache.h Run pgindent on 9.2 source tree in preparation for first 9.3 2012-06-10 15:20:04 -04:00
tzparser.h Update copyright notices for year 2012. 2012-01-01 18:01:58 -05:00
uuid.h Update copyright notices for year 2012. 2012-01-01 18:01:58 -05:00
varbit.h Add a transform function for varbit typmod coercisions. 2012-02-07 12:42:50 -05:00
xml.h Run pgindent on 9.2 source tree in preparation for first 9.3 2012-06-10 15:20:04 -04:00