Fix an oversight in ReorderBufferFinishPrepared.
We don't have anything to decode in a transaction if ReorderBufferTXN
doesn't exist by the time we decode the commit prepared. So don't create a
new ReorderBufferTXN here. This is an oversight in commit
Reported-by: Markus Wanner
Discussion:
@@ -2679,7 +2679,7 @@ ReorderBufferFinishPrepared(ReorderBuffer *rb, TransactionId xid,
XLogRecPtr prepare_end_lsn;
TimestampTz prepare_time;
- txn = ReorderBufferTXNByXid(rb, xid, true, NULL, commit_lsn, false);
+ txn = ReorderBufferTXNByXid(rb, xid, false, NULL, commit_lsn, false);
/* unknown transaction, nothing to do */
if (txn == NULL)
