diff options
author | Hennadii Stepanov <32963518+hebasto@users.noreply.github.com> | 2020-08-25 01:58:15 +0300 |
---|---|---|
committer | Hennadii Stepanov <32963518+hebasto@users.noreply.github.com> | 2020-09-07 21:03:55 +0300 |
commit | ddefb5c0b759950942ac03f28c43b548af7b4033 (patch) | |
tree | d1b98e57c96e22669969ec20c1d450a5da93f96b /src/net.cpp | |
parent | e084d45562b94827b3a7873895882fcaae9f4d48 (diff) |
p2p: Use the greatest common version in peer logic
Diffstat (limited to 'src/net.cpp')
-rw-r--r-- | src/net.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/net.cpp b/src/net.cpp index 84f1f9f068..db44e8cbb0 100644 --- a/src/net.cpp +++ b/src/net.cpp @@ -1167,7 +1167,7 @@ void CConnman::InactivityCheck(CNode *pnode) LogPrintf("socket sending timeout: %is\n", nTime - pnode->nLastSend); pnode->fDisconnect = true; } - else if (nTime - pnode->nLastRecv > (pnode->nVersion > BIP0031_VERSION ? TIMEOUT_INTERVAL : 90*60)) + else if (nTime - pnode->nLastRecv > (pnode->GetCommonVersion() > BIP0031_VERSION ? TIMEOUT_INTERVAL : 90*60)) { LogPrintf("socket receive timeout: %is\n", nTime - pnode->nLastRecv); pnode->fDisconnect = true; |