pgsql: Fix overflow danger in SampleHeapTupleVisible(), take 2 - Mailing list pgsql-committers

From Melanie Plageman
Subject pgsql: Fix overflow danger in SampleHeapTupleVisible(), take 2
Date
Msg-id E1tOeEr-000XSA-J1@gemulon.postgresql.org
Whole thread Raw
List pgsql-committers
Fix overflow danger in SampleHeapTupleVisible(), take 2

28328ec87b45725 addressed one overflow danger in
SampleHeapTupleVisible() but introduced another, albeit a less likely
one. Modify the binary search code to remove this danger.

Reported-by: Richard Guo
Reviewed-by: Richard Guo, Ranier Vilela
Discussion: https://postgr.es/m/CAMbWs4_bE%2BNscChbKWzw6HZOipCUyXfA5133qvoXQ654D3B2gQ%40mail.gmail.com

Branch
------
master

Details
-------
https://git.postgresql.org/pg/commitdiff/94bb6c4410d81ccc019bb60d8aedb73dbc85df76

Modified Files
--------------
src/backend/access/heap/heapam_handler.c | 16 +++++-----------
1 file changed, 5 insertions(+), 11 deletions(-)


pgsql-committers by date:

Previous
From: Thomas Munro
Date:
Subject: pgsql: Fix corruption when relation truncation fails.
Next
From: Heikki Linnakangas
Date:
Subject: pgsql: Fix variable reference in comment