aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorPieter Wuille <pieter.wuille@gmail.com>2012-05-12 17:44:14 +0200
committerPieter Wuille <pieter.wuille@gmail.com>2012-05-13 00:49:12 +0200
commit89b5616d107294a1f496226f22b9966e4221cf35 (patch)
treeb037119fd4bbe79a317490d7510e92c644df450d /src
parent45dcf63a62402248bb5e54d5eb8985dd4d90db1b (diff)
Do not signal outbound semaphore if uninitialized
Diffstat (limited to 'src')
-rw-r--r--src/net.cpp5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/net.cpp b/src/net.cpp
index f12afb78e6..0e5a89878d 100644
--- a/src/net.cpp
+++ b/src/net.cpp
@@ -1887,8 +1887,9 @@ bool StopNode()
fShutdown = true;
nTransactionsUpdated++;
int64 nStart = GetTime();
- for (int i=0; i<MAX_OUTBOUND_CONNECTIONS; i++)
- semOutbound->post();
+ if (semOutbound)
+ for (int i=0; i<MAX_OUTBOUND_CONNECTIONS; i++)
+ semOutbound->post();
do
{
int nThreadsRunning = 0;