Skip to content

Commit f371cc9

Browse files
committed
Fix potential data corruption during freeze
Fix oversight in 3b97e68 bug fix. Bitwise AND is used instead of OR and it cleans all bits in t_infomask heap tuple field. Backpatch to 9.3
1 parent 543e00b commit f371cc9

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/backend/access/heap/heapam.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5737,7 +5737,7 @@ heap_prepare_freeze_tuple(HeapTupleHeader tuple, TransactionId cutoff_xid,
57375737
frz->t_infomask &= ~HEAP_XMAX_BITS;
57385738
frz->xmax = newxmax;
57395739
if (flags & FRM_MARK_COMMITTED)
5740-
frz->t_infomask &= HEAP_XMAX_COMMITTED;
5740+
frz->t_infomask |= HEAP_XMAX_COMMITTED;
57415741
changed = true;
57425742
}
57435743
else if (flags & FRM_RETURN_IS_MULTI)

0 commit comments

Comments
 (0)