Revert "Delete old protocol version constants and simplify code that used them."

This reverts commit 5a49c929dd.
This commit is contained in:
Sean Bowe
2017-06-23 18:19:25 -06:00
parent 9ad9a25eff
commit 15a9937654
4 changed files with 56 additions and 21 deletions

View File

@@ -1194,7 +1194,7 @@ void ThreadSocketHandler()
LogPrintf("socket sending timeout: %is\n", nTime - pnode->nLastSend);
pnode->fDisconnect = true;
}
else if (nTime - pnode->nLastRecv > TIMEOUT_INTERVAL)
else if (nTime - pnode->nLastRecv > (pnode->nVersion > BIP0031_VERSION ? TIMEOUT_INTERVAL : 90*60))
{
LogPrintf("socket receive timeout: %is\n", nTime - pnode->nLastRecv);
pnode->fDisconnect = true;