Skip to content

Commit c452676

Browse files
TheBlueMattfurszy
authored andcommitted
Make the cs_sendProcessing a LOCK instead of a TRY_LOCK
Technically cs_sendProcessing is entirely useless now because it is only ever taken on the one MessageHandler thread, but because there may be multiple of those in the future, it is left in place
1 parent ec23964 commit c452676

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

src/net.cpp

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1841,9 +1841,8 @@ void ThreadMessageHandler()
18411841

18421842
// Send messages
18431843
{
1844-
TRY_LOCK(pnode->cs_sendProcessing, lockSend);
1845-
if (lockSend)
1846-
GetNodeSignals().SendMessages(pnode);
1844+
LOCK(pnode->cs_sendProcessing);
1845+
GetNodeSignals().SendMessages(pnode);
18471846
}
18481847
boost::this_thread::interruption_point();
18491848
}

0 commit comments

Comments
 (0)