Fix incorrect initialization of ProcGlobal->startupBufferPinWaitBufId.
Tom Lane <tgl@sss.pgh.pa.us>
Fix incorrect initialization of ProcGlobal->startupBufferPinWaitBufId. It was initialized in the wrong place and to the wrong value. With bad luck this could result in incorrect query-cancellation failures in hot standby sessions, should a HS backend be holding pin on buffer number 1 while trying to acquire a lock.
Files
| Path | Change | +/− |
|---|---|---|
| src/backend/storage/buffer/bufmgr.c | modified | +2 −1 |
| src/backend/storage/lmgr/proc.c | modified | +4 −6 |
| src/include/storage/proc.h | modified | +1 −1 |