Commit 31b8db8e authored by Teodor Sigaev's avatar Teodor Sigaev

Fix potential data corruption during freeze

Fix oversight in 3b97e682 bug fix. Bitwise AND is used instead of OR and
it cleans all bits in t_infomask heap tuple field.

Backpatch to 9.3
parent f1dae097
......@@ -6627,7 +6627,7 @@ heap_prepare_freeze_tuple(HeapTupleHeader tuple, TransactionId cutoff_xid,
frz->t_infomask &= ~HEAP_XMAX_BITS;
frz->xmax = newxmax;
if (flags & FRM_MARK_COMMITTED)
frz->t_infomask &= HEAP_XMAX_COMMITTED;
frz->t_infomask |= HEAP_XMAX_COMMITTED;
changed = true;
totally_frozen = false;
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment