Thread: pgsql: Fix race condition where heap_delete() fails to pin VM page.

pgsql: Fix race condition where heap_delete() fails to pin VM page.

From
Jeff Davis
Date:
Fix race condition where heap_delete() fails to pin VM page.

Similar to 5f12bc94dc, the code must re-check PageIsAllVisible() after
buffer lock is re-acquired. Backpatching to the same version, 12.

Discussion: https://postgr.es/m/CAEP4nAw9jYQDKd_5Y+-s2E4YiUJq1vqiikFjYGpLShtp-K3gag@mail.gmail.com
Reported-by: Robins Tharakan
Reviewed-by: Robins Tharakan
Backpatch-through: 12

Branch
------
REL_15_STABLE

Details
-------
https://git.postgresql.org/pg/commitdiff/dd6070bc81733c3174f2e257d43908f98b0255fb

Modified Files
--------------
src/backend/access/heap/heapam.c | 30 +++++++++++++++++++-----------
1 file changed, 19 insertions(+), 11 deletions(-)