diff options
| author | Pieter Wuille <[email protected]> | 2016-03-26 13:31:25 +0100 |
|---|---|---|
| committer | Pieter Wuille <[email protected]> | 2016-06-13 17:40:16 +0200 |
| commit | 5e7ab16d29ac66a5a5753dd4f59b6fb12e60654e (patch) | |
| tree | bffac27c15553b6b5e32086d96bdf7deb701f0c4 /src/net.cpp | |
| parent | Verify that outbound connections have expected services (diff) | |
| download | discoin-5e7ab16d29ac66a5a5753dd4f59b6fb12e60654e.tar.xz discoin-5e7ab16d29ac66a5a5753dd4f59b6fb12e60654e.zip | |
Only store and connect to NODE_NETWORK nodes
Diffstat (limited to 'src/net.cpp')
| -rw-r--r-- | src/net.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/net.cpp b/src/net.cpp index a0c2bd509..395e1fe42 100644 --- a/src/net.cpp +++ b/src/net.cpp @@ -1596,6 +1596,10 @@ void ThreadOpenConnections() if (IsLimited(addr)) continue; + // only connect to full nodes + if (!(addr.nServices & NODE_NETWORK)) + continue; + // only consider very recently tried nodes after 30 failed attempts if (nANow - addr.nLastTry < 600 && nTries < 30) continue; |