We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent bfc79ee commit e1b13ccCopy full SHA for e1b13cc
src/backend/access/transam/twophase.c
@@ -2633,6 +2633,7 @@ PrepareRedoRemove(TransactionId xid, bool giveWarning)
2633
{
2634
GlobalTransaction gxact = NULL;
2635
int i;
2636
+ bool found = false;
2637
2638
Assert(LWLockHeldByMeInMode(TwoPhaseStateLock, LW_EXCLUSIVE));
2639
Assert(RecoveryInProgress());
@@ -2644,14 +2645,15 @@ PrepareRedoRemove(TransactionId xid, bool giveWarning)
2644
2645
if (gxact->xid == xid)
2646
2647
Assert(gxact->inredo);
2648
+ found = true;
2649
break;
2650
}
2651
2652
2653
/*
2654
* Just leave if there is nothing, this is expected during WAL replay.
2655
*/
- if (gxact == NULL)
2656
+ if (!found)
2657
return;
2658
2659
0 commit comments