Skip to content

Commit

Permalink
Fix mistakenly swapped "previous" and "current" lock orders
Browse files Browse the repository at this point in the history
  • Loading branch information
hebasto committed Jun 22, 2020
1 parent 8ef15e8 commit 3559934
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/sync.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ static void potential_deadlock_detected(const LockPair& mismatch, const LockStac
{
LogPrintf("POTENTIAL DEADLOCK DETECTED\n");
LogPrintf("Previous lock order was:\n");
for (const LockStackItem& i : s2) {
for (const LockStackItem& i : s1) {
if (i.first == mismatch.first) {
LogPrintf(" (1)"); /* Continued */
}
Expand All @@ -115,7 +115,7 @@ static void potential_deadlock_detected(const LockPair& mismatch, const LockStac
LogPrintf(" %s\n", i.second.ToString());
}
LogPrintf("Current lock order is:\n");
for (const LockStackItem& i : s1) {
for (const LockStackItem& i : s2) {
if (i.first == mismatch.first) {
LogPrintf(" (1)"); /* Continued */
}
Expand Down

0 comments on commit 3559934

Please sign in to comment.