]> granicus.if.org Git - postgresql/commit
Relax overly strict sanity check for upgraded ancient databases
authorAlvaro Herrera <alvherre@alvh.no-ip.org>
Thu, 1 Mar 2018 21:07:46 +0000 (18:07 -0300)
committerAlvaro Herrera <alvherre@alvh.no-ip.org>
Thu, 1 Mar 2018 21:07:46 +0000 (18:07 -0300)
commit0ddaaa4cf4ff6e200767daf831e4cd955bafaa61
treec8c294dd09536b81f0162a4d8a65fdddeb5aadbf
parent3f26be83ec1e8976566d020da738c032c4aee3f3
Relax overly strict sanity check for upgraded ancient databases

Commit 4800f16a7ad0 added some sanity checks to ensure we don't
accidentally corrupt data, but in one of them we failed to consider the
effects of a database upgraded from 9.2 or earlier, where a tuple
exclusively locked prior to the upgrade has a slightly different bit
pattern.  Fix that by using the macro that we fixed in commit
74ebba84aeb6 for similar situations.

Reported-by: Alexandre Garcia
Reviewed-by: Andres Freund
Discussion: https://postgr.es/m/CAPYLKR6yxV4=pfW0Gwij7aPNiiPx+3ib4USVYnbuQdUtmkMaEA@mail.gmail.com

Andres suspects that this bug may have wider ranging consequences, but I
couldn't find anything.
src/backend/access/heap/heapam.c