aboutsummaryrefslogtreecommitdiff
path: root/src/backend/utils/adt/jsonfuncs.c
diff options
context:
space:
mode:
authorAndres Freund <andres@anarazel.de>2023-03-11 14:12:51 -0800
committerAndres Freund <andres@anarazel.de>2023-03-11 14:14:56 -0800
commita42f515d6b45ea19b96fb2868d8acb77251d911d (patch)
tree1ad229d5ae3baceede79c2cd81dd3e6cff3d39da /src/backend/utils/adt/jsonfuncs.c
parent786528039911c2270589bb690afab20116ee88f3 (diff)
downloadpostgresql-a42f515d6b45ea19b96fb2868d8acb77251d911d.tar.gz
postgresql-a42f515d6b45ea19b96fb2868d8acb77251d911d.zip
amcheck: Fix ordering bug in update_cached_xid_range()
The initialization order in update_cached_xid_range() was wrong, calling FullTransactionIdFromXidAndCtx() before setting ->next_xid. FullTransactionIdFromXidAndCtx() uses ->next_xid. In most situations this will not cause visible issues, because the next call to update_cached_xid_range() will use a less wrong ->next_xid. It's rare that xids advance fast enough for this to be a problem. Found while adding more asserts to the 64bit xid infrastructure. Reviewed-by: Mark Dilger <mark.dilger@enterprisedb.com> Discussion: https://postgr.es/m/20230108002923.cyoser3ttmt63bfn@awork3.anarazel.de Backpatch: 14-, where heapam verification was introduced
Diffstat (limited to 'src/backend/utils/adt/jsonfuncs.c')
0 files changed, 0 insertions, 0 deletions