Content-Length: 300570 | pFad | http://github.com/postgrespro/postgres_cluster/commit/aeecdacf0621773d88dc78cc70a53622dcc073bb

EE Uncomment assert · postgrespro/postgres_cluster@aeecdac · GitHub
Skip to content

Commit aeecdac

Browse files
committed
Uncomment assert
1 parent 1c1434b commit aeecdac

File tree

2 files changed

+7
-7
lines changed

2 files changed

+7
-7
lines changed

src/backend/access/transam/clog.c

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -352,10 +352,10 @@ TransactionIdSetStatusBit(TransactionId xid, XidStatus status, XLogRecPtr lsn, i
352352
* Current state change should be from 0 or subcommitted to target state
353353
* or we should already be there when replaying changes during recovery.
354354
*/
355-
/* Assert(curval == 0 || */
356-
/* (curval == TRANSACTION_STATUS_SUB_COMMITTED && */
357-
/* status != TRANSACTION_STATUS_IN_PROGRESS) || */
358-
/* curval == status); */
355+
Assert(curval == 0 ||
356+
(curval == TRANSACTION_STATUS_SUB_COMMITTED &&
357+
status != TRANSACTION_STATUS_IN_PROGRESS) ||
358+
curval == status);
359359

360360
/* note this assumes exclusive access to the clog page */
361361
byteval = *byteptr;

src/backend/access/transam/xact.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1543,9 +1543,9 @@ RecordTransactionAbort(bool isSubXact)
15431543
/*
15441544
* Check that we haven't aborted halfway through RecordTransactionCommit.
15451545
*/
1546-
/* if (TransactionIdDidCommit(xid)) */
1547-
/* elog(PANIC, "cannot abort transaction %u, it was already committed", */
1548-
/* xid); */
1546+
if (TransactionIdDidCommit(xid))
1547+
elog(PANIC, "cannot abort transaction %u, it was already committed",
1548+
xid);
15491549

15501550
/* Fetch the data we need for the abort record */
15511551
nrels = smgrGetPendingDeletes(false, &rels);

0 commit comments

Comments
 (0)








ApplySandwichStrip

pFad - (p)hone/(F)rame/(a)nonymizer/(d)eclutterfier!      Saves Data!


--- a PPN by Garber Painting Akron. With Image Size Reduction included!

Fetched URL: http://github.com/postgrespro/postgres_cluster/commit/aeecdacf0621773d88dc78cc70a53622dcc073bb

Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy