Skip to content

Commit 3559934

Browse files
committed
Fix mistakenly swapped "previous" and "current" lock orders
1 parent 8ef15e8 commit 3559934

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/sync.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -105,7 +105,7 @@ static void potential_deadlock_detected(const LockPair& mismatch, const LockStac
105105
{
106106
LogPrintf("POTENTIAL DEADLOCK DETECTED\n");
107107
LogPrintf("Previous lock order was:\n");
108-
for (const LockStackItem& i : s2) {
108+
for (const LockStackItem& i : s1) {
109109
if (i.first == mismatch.first) {
110110
LogPrintf(" (1)"); /* Continued */
111111
}
@@ -115,7 +115,7 @@ static void potential_deadlock_detected(const LockPair& mismatch, const LockStac
115115
LogPrintf(" %s\n", i.second.ToString());
116116
}
117117
LogPrintf("Current lock order is:\n");
118-
for (const LockStackItem& i : s1) {
118+
for (const LockStackItem& i : s2) {
119119
if (i.first == mismatch.first) {
120120
LogPrintf(" (1)"); /* Continued */
121121
}

0 commit comments

Comments
 (0)