|
|
@ -156,7 +156,6 @@ bool Session::interpret(PacketType _t, RLP const& _r) |
|
|
|
clogS(NetRight) << _t << _r; |
|
|
|
try // Generic try-catch block designed to capture RLP format errors - TODO: give decent diagnostics, make a bit more specific over what is caught.
|
|
|
|
{ |
|
|
|
|
|
|
|
switch (_t) |
|
|
|
{ |
|
|
|
case DisconnectPacket: |
|
|
@ -185,7 +184,6 @@ bool Session::interpret(PacketType _t, RLP const& _r) |
|
|
|
clogS(NetTriviaSummary) << "Latency: " << chrono::duration_cast<chrono::milliseconds>(m_info.lastPing).count() << " ms"; |
|
|
|
break; |
|
|
|
case GetPeersPacket: |
|
|
|
{ |
|
|
|
// Disabled for interop testing.
|
|
|
|
// GetPeers/PeersPacket will be modified to only exchange new nodes which it's peers are interested in.
|
|
|
|
break; |
|
|
@ -194,7 +192,6 @@ bool Session::interpret(PacketType _t, RLP const& _r) |
|
|
|
m_theyRequestedNodes = true; |
|
|
|
serviceNodesRequest(); |
|
|
|
break; |
|
|
|
} |
|
|
|
case PeersPacket: |
|
|
|
// Disabled for interop testing.
|
|
|
|
// GetPeers/PeersPacket will be modified to only exchange new nodes which it's peers are interested in.
|
|
|
@ -247,7 +244,6 @@ bool Session::interpret(PacketType _t, RLP const& _r) |
|
|
|
} |
|
|
|
break; |
|
|
|
default: |
|
|
|
{ |
|
|
|
for (auto const& i: m_capabilities) |
|
|
|
if (_t >= i.second->m_idOffset && _t - i.second->m_idOffset < i.second->hostCapability()->messageCount()) |
|
|
|
{ |
|
|
@ -259,7 +255,6 @@ bool Session::interpret(PacketType _t, RLP const& _r) |
|
|
|
return false; |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
catch (std::exception const& _e) |
|
|
|
{ |
|
|
|
clogS(NetWarn) << "Peer causing an exception:" << _e.what() << _r; |
|
|
|