File tree Expand file tree Collapse file tree
framework/src/main/java/org/tron/core/net Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -139,6 +139,7 @@ private P2pConfig getConfig() {
139139 config .setActiveNodes (parameter .getActiveNodes ());
140140 config .setTrustNodes (parameter .getPassiveNodes ());
141141 config .getActiveNodes ().forEach (n -> config .getTrustNodes ().add (n .getAddress ()));
142+ parameter .getFastForwardNodes ().forEach (f -> config .getTrustNodes ().add (f .getAddress ()));
142143 int maxConnections = parameter .getMaxConnections ();
143144 int minConnections = parameter .getMinConnections ();
144145 int minActiveConnections = parameter .getMinActiveConnections ();
Original file line number Diff line number Diff line change @@ -147,7 +147,7 @@ public class PeerConnection {
147147
148148 public void setChannel (Channel channel ) {
149149 this .channel = channel ;
150- if (relayNodes .contains ( channel .getInetSocketAddress ( ))) {
150+ if (relayNodes .stream (). anyMatch ( n -> n . getAddress (). equals ( channel .getInetAddress () ))) {
151151 this .isRelayPeer = true ;
152152 }
153153 this .nodeStatistics = TronStatsManager .getNodeStatistics (channel .getInetAddress ());
You can’t perform that action at this time.
0 commit comments