aboutsummaryrefslogtreecommitdiff
path: root/src/main.cpp
diff options
context:
space:
mode:
authorWarren Togami <wtogami@gmail.com>2013-10-25 23:21:21 -1000
committerWarren Togami <wtogami@gmail.com>2013-10-25 23:46:37 -1000
commit1ce418929a17c063a0a2e3b176b82d280ef053a6 (patch)
tree50370fb2ae945912b23814c6c1bc0e6a3ca9e4bb /src/main.cpp
parent0d09b3e8b0218169ab7ad2aa787c43ea11bc7060 (diff)
downloadbitcoin-1ce418929a17c063a0a2e3b176b82d280ef053a6.tar.xz
Split MIN_PROTO_VERSION into INIT_PROTO_VERSION and MIN_PEER_PROTO_VERSION
INIT_PROTO_VERSION is the initial version, after a succesful version/verack it is increased to a negotiated version. MIN_PEER_PROTO_VERSION could be a different value to disconnect from peers older than a specified version.
Diffstat (limited to 'src/main.cpp')
-rw-r--r--src/main.cpp5
1 files changed, 2 insertions, 3 deletions
diff --git a/src/main.cpp b/src/main.cpp
index 01a1babc7f..0c775b6779 100644
--- a/src/main.cpp
+++ b/src/main.cpp
@@ -3377,10 +3377,9 @@ bool static ProcessMessage(CNode* pfrom, string strCommand, CDataStream& vRecv)
CAddress addrFrom;
uint64 nNonce = 1;
vRecv >> pfrom->nVersion >> pfrom->nServices >> nTime >> addrMe;
- if (pfrom->nVersion < MIN_PROTO_VERSION)
+ if (pfrom->nVersion < MIN_PEER_PROTO_VERSION)
{
- // Since February 20, 2012, the protocol is initiated at version 209,
- // and earlier versions are no longer supported
+ // disconnect from peers older than this proto version
LogPrintf("partner %s using obsolete version %i; disconnecting\n", pfrom->addr.ToString().c_str(), pfrom->nVersion);
pfrom->fDisconnect = true;
return false;