Changeset View
Changeset View
Standalone View
Standalone View
src/net_processing.cpp
Show First 20 Lines • Show All 2,283 Lines • ▼ Show 20 Lines | if (strCommand == NetMsgType::VERSION) { | ||||
pfrom->addr.ToString(), cleanSubVer, pfrom->nVersion, | pfrom->addr.ToString(), cleanSubVer, pfrom->nVersion, | ||||
pfrom->nStartingHeight, addrMe.ToString(), pfrom->GetId(), | pfrom->nStartingHeight, addrMe.ToString(), pfrom->GetId(), | ||||
remoteAddr); | remoteAddr); | ||||
int64_t nTimeOffset = nTime - GetTime(); | int64_t nTimeOffset = nTime - GetTime(); | ||||
pfrom->nTimeOffset = nTimeOffset; | pfrom->nTimeOffset = nTimeOffset; | ||||
AddTimeData(pfrom->addr, nTimeOffset); | AddTimeData(pfrom->addr, nTimeOffset); | ||||
// If the peer is old enough to have the old alert system, send it the | |||||
// final alert. | |||||
if (pfrom->nVersion <= 70012) { | |||||
CDataStream finalAlert( | |||||
ParseHex( | |||||
"60010000000000000000000000ffffff7f00000000ffffff7ffeffff7f" | |||||
"01ffffff7f00000000ffffff7f00ffffff7f002f555247454e543a2041" | |||||
"6c657274206b657920636f6d70726f6d697365642c2075706772616465" | |||||
"207265717569726564004630440220653febd6410f470f6bae11cad19c" | |||||
"48413becb1ac2c17f908fd0fd53bdc3abd5202206d0e9c96fe88d4a0f0" | |||||
"1ed9dedae2b6f9e00da94cad0fecaae66ecf689bf71b50"), | |||||
SER_NETWORK, PROTOCOL_VERSION); | |||||
connman->PushMessage( | |||||
pfrom, CNetMsgMaker(nSendVersion).Make("alert", finalAlert)); | |||||
} | |||||
// Feeler connections exist only to verify if address is online. | // Feeler connections exist only to verify if address is online. | ||||
if (pfrom->fFeeler) { | if (pfrom->fFeeler) { | ||||
assert(pfrom->fInbound == false); | assert(pfrom->fInbound == false); | ||||
pfrom->fDisconnect = true; | pfrom->fDisconnect = true; | ||||
} | } | ||||
return true; | return true; | ||||
} | } | ||||
▲ Show 20 Lines • Show All 2,560 Lines • Show Last 20 Lines |