Some cleanup, and use VERB_PUSH_DIRECT_PATHS to redirect newer peers.

This commit is contained in:
Adam Ierymenko 2015-10-27 09:53:43 -07:00
parent fb3b7a3baa
commit 9617208e40
3 changed files with 36 additions and 19 deletions

View file

@ -280,8 +280,8 @@ bool IncomingPacket::_doHELLO(const RuntimeEnvironment *RR)
// VALID -- if we made it here, packet passed identity and authenticity checks!
peer->received(RR,_localAddress,_remoteAddress,hops(),pid,Packet::VERB_HELLO,0,Packet::VERB_NOP);
peer->setRemoteVersion(protoVersion,vMajor,vMinor,vRevision);
peer->received(RR,_localAddress,_remoteAddress,hops(),pid,Packet::VERB_HELLO,0,Packet::VERB_NOP);
if (destAddr)
RR->sa->iam(id.address(),_remoteAddress,destAddr,RR->topology->isRoot(id),RR->node->now());