diff options
author | Cory Fields <cory-nospam-@coryfields.com> | 2016-09-13 14:42:55 -0400 |
---|---|---|
committer | Cory Fields <cory-nospam-@coryfields.com> | 2016-09-13 22:43:23 -0400 |
commit | 36fa01f217fbc32afb90314fd257650c71a47045 (patch) | |
tree | 30e238e40abdffd1f476de554e13cf824a5bd638 /src/net.cpp | |
parent | fa7caf6d9116c35433a2069174f4c66f051d52ba (diff) |
net: only delete CConnman if it's been created
In the case of (for example) an already-running bitcoind, the shutdown sequence
begins before CConnman has been created, leading to a null-pointer dereference
when g_connman->Stop() is called.
Instead, Just let the CConnman dtor take care of stopping.
Diffstat (limited to 'src/net.cpp')
-rw-r--r-- | src/net.cpp | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/src/net.cpp b/src/net.cpp index b39ef9f54a..30513a3b9a 100644 --- a/src/net.cpp +++ b/src/net.cpp @@ -2205,6 +2205,7 @@ void CConnman::DeleteNode(CNode* pnode) CConnman::~CConnman() { + Stop(); } size_t CConnman::GetAddressCount() const |