postgresql/src/include
Tom Lane a2e923a652 Fix dynahash.c to suppress hash bucket splits while a hash_seq_search() scan
is in progress on the same hashtable.  This seems the least invasive way to
fix the recently-recognized problem that a split could cause the scan to
visit entries twice or (with much lower probability) miss them entirely.
The only field-reported problem caused by this is the "failed to re-find
shared lock object" PANIC in COMMIT PREPARED reported by Michel Dorochevsky,
which was caused by multiply visited entries.  However, it seems certain
that mdsync() is vulnerable to missing required fsync's due to missed
entries, and I am fearful that RelationCacheInitializePhase2() might be at
risk as well.  Because of that and the generalized hazard presented by this
bug, back-patch all the supported branches.

Along the way, fix pg_prepared_statement() and pg_cursor() to not assume
that the hashtables they are examining will stay static between calls.
This is risky regardless of the newly noted dynahash problem, because
hash_seq_search() has never promised to cope with deletion of table entries
other than the just-returned one.  There may be no bug here because the only
supported way to call these functions is via ExecMakeTableFunctionResult()
which will cycle them to completion before doing anything very interesting,
but it seems best to get rid of the assumption.  This affects 8.2 and HEAD
only, since those functions weren't there earlier.
2007-04-26 23:24:46 +00:00
..
access Repair PANIC condition in hash indexes when a previous index extension attempt 2007-04-19 20:24:04 +00:00
bootstrap Cleanup the bootstrap code a little, and rename "dummy procs" in the code 2007-03-07 13:35:03 +00:00
catalog Make JOHAB client only encoding per discussions in pgsql-hackers 2007-04-15 10:56:30 +00:00
commands Rename the newly-added commands for discarding session state. 2007-04-26 16:13:15 +00:00
executor Support scrollable cursors (ie, 'direction' clause in FETCH) in plpgsql. 2007-04-16 17:21:24 +00:00
lib Add resetStringInfo(), which clears the content of a StringInfo, and 2007-03-03 19:32:55 +00:00
libpq Add lo_truncate() to backend and libpq for large object truncation. 2007-03-03 19:52:47 +00:00
mb Make JOHAB client only encoding per discussions in pgsql-hackers 2007-04-15 10:56:30 +00:00
nodes Fix dynahash.c to suppress hash bucket splits while a hash_seq_search() scan 2007-04-26 23:24:46 +00:00
optimizer Expose more cursor-related functionality in SPI: specifically, allow 2007-04-16 01:14:58 +00:00
parser Support enum data types. Along the way, use macros for the values of 2007-04-02 03:49:42 +00:00
port Now that core functionality is depending on autoconf's AC_C_BIGENDIAN to be 2007-04-06 05:36:51 +00:00
postmaster Enable configurable log of autovacuum actions. Initial patch from Simon 2007-04-18 16:44:18 +00:00
regex Wording cleanup for error messages. Also change can't -> cannot. 2007-02-01 19:10:30 +00:00
rewrite Changes pg_trigger and extend pg_rewrite in order to allow triggers and 2007-03-19 23:38:32 +00:00
storage Add a multi-worker capability to autovacuum. This allows multiple worker 2007-04-16 18:30:04 +00:00
tcop Expose more cursor-related functionality in SPI: specifically, allow 2007-04-16 01:14:58 +00:00
utils Fix dynahash.c to suppress hash bucket splits while a hash_seq_search() scan 2007-04-26 23:24:46 +00:00
c.h Replace direct assignments to VARATT_SIZEP(x) with SET_VARSIZE(x, len). 2007-02-27 23:48:10 +00:00
fmgr.h Support varlena fields with single-byte headers and unaligned storage. 2007-04-06 04:21:44 +00:00
funcapi.h Update CVS HEAD for 2007 copyright. Back branches are typically not 2007-01-05 22:20:05 +00:00
getaddrinfo.h Update CVS HEAD for 2007 copyright. Back branches are typically not 2007-01-05 22:20:05 +00:00
getopt_long.h Update CVS HEAD for 2007 copyright. Back branches are typically not 2007-01-05 22:20:05 +00:00
Makefile Allow installation into directories containing spaces in the name. 2005-12-09 21:19:36 +00:00
miscadmin.h Add a multi-worker capability to autovacuum. This allows multiple worker 2007-04-16 18:30:04 +00:00
pg_config.h.in Add --with-libxslt configure option 2007-04-15 12:48:24 +00:00
pg_config.h.win32 Enable IPV6 for all MSVC builds, including the VC6 libpq-only build. 2007-04-16 18:39:19 +00:00
pg_config_manual.h Move BLCKSZ < 1024 check to guc.c. 2007-02-23 21:36:19 +00:00
pg_trace.h pgindent run for 8.2. 2006-10-04 00:30:14 +00:00
pgstat.h Add some instrumentation to the bgwriter, through the stats collector. 2007-03-30 18:34:56 +00:00
pgtime.h Update CVS HEAD for 2007 copyright. Back branches are typically not 2007-01-05 22:20:05 +00:00
port.h Add O_DIRECT support on Windows. 2007-04-13 10:30:30 +00:00
postgres.h Support varlena fields with single-byte headers and unaligned storage. 2007-04-06 04:21:44 +00:00
postgres_ext.h Move NAMEDATALEN definition from postgres_ext.h to pg_config_manual.h. It 2007-02-06 09:16:08 +00:00
postgres_fe.h Update CVS HEAD for 2007 copyright. Back branches are typically not 2007-01-05 22:20:05 +00:00
rusagestub.h Update CVS HEAD for 2007 copyright. Back branches are typically not 2007-01-05 22:20:05 +00:00