File tree Expand file tree Collapse file tree 2 files changed +6
-6
lines changed
main/java/org/tron/core/net/peer
test/java/org/tron/core/net/peer Expand file tree Collapse file tree 2 files changed +6
-6
lines changed Original file line number Diff line number Diff line change @@ -197,10 +197,10 @@ public void onConnect() {
197197 public void onDisconnect () {
198198 syncService .onDisconnect (this );
199199 advService .onDisconnect (this );
200- advInvReceive .cleanUp ();
201- advInvSpread .cleanUp ();
200+ advInvReceive .invalidateAll ();
201+ advInvSpread .invalidateAll ();
202202 advInvRequest .clear ();
203- syncBlockIdCache .cleanUp ();
203+ syncBlockIdCache .invalidateAll ();
204204 syncBlockToFetch .clear ();
205205 syncBlockRequested .clear ();
206206 syncBlockInProcess .clear ();
Original file line number Diff line number Diff line change @@ -60,9 +60,9 @@ public void testOnDisconnect() {
6060
6161 peerConnection .onDisconnect ();
6262
63- // Assert.assertEquals(0, peerConnection.getAdvInvReceive().size());
64- // Assert.assertEquals(0, peerConnection.getAdvInvSpread().size());
65- // Assert.assertEquals(0, peerConnection.getSyncBlockIdCache().size());
63+ Assert .assertEquals (0 , peerConnection .getAdvInvReceive ().size ());
64+ Assert .assertEquals (0 , peerConnection .getAdvInvSpread ().size ());
65+ Assert .assertEquals (0 , peerConnection .getSyncBlockIdCache ().size ());
6666 Assert .assertEquals (0 , peerConnection .getSyncBlockToFetch ().size ());
6767 Assert .assertEquals (0 , peerConnection .getSyncBlockRequested ().size ());
6868 Assert .assertEquals (0 , peerConnection .getSyncBlockInProcess ().size ());
You can’t perform that action at this time.
0 commit comments