Fix oversight in sizing of shared buffer lookup hashtable. Because

Tom Lane <tgl@sss.pgh.pa.us>

Commit: b25dc481c8cf2d5ec894b6267ca97939997c698e
Author: Tom Lane <tgl@sss.pgh.pa.us>
Date: 2006-07-23T18:34:45Z
Releases: 8.2.0
Fix oversight in sizing of shared buffer lookup hashtable.  Because
BufferAlloc tries to insert a new mapping entry before deleting the old one
for a buffer, we have a transient need for more than NBuffers entries ---
one more in 8.1, and as many as NUM_BUFFER_PARTITIONS more in CVS HEAD.
In theory this could lead to an "out of shared memory" failure if shmem
had already been completely claimed by the time the extra entries were
needed.

Files

PathChange+/−
src/backend/storage/buffer/freelist.c modified +11 −4