Add some code to Assert that when we release pin on a buffer, we are
Tom Lane <tgl@sss.pgh.pa.us>
Add some code to Assert that when we release pin on a buffer, we are not holding the buffer's cntx_lock or io_in_progress_lock. A recent report from Litao Wu makes me wonder whether it is ever possible for us to drop a buffer and forget to release its cntx_lock. The Assert does not fire in the regression tests, but that proves little ...
Files
| Path | Change | +/− |
|---|---|---|
| src/backend/storage/buffer/bufmgr.c | modified | +6 −1 |
| src/backend/storage/lmgr/lwlock.c | modified | +21 −1 |
| src/include/storage/lwlock.h | modified | +2 −1 |