From 72d1b33aa2f0f816f96078da0c580ec486655d45 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Tom=C3=A1=C5=A1=20Brada?= Date: Tue, 15 Dec 2015 20:24:47 +0100 Subject: [PATCH] Drop nodes with same ID but different address. --- dht.pas | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dht.pas b/dht.pas index 0faa258..a74038d 100644 --- a/dht.pas +++ b/dht.pas @@ -164,7 +164,7 @@ procedure UpdateNode(const id:tFID; const addr:tNetAddr); do if (fr=0)and bkt^.peer[i].addr.isNil then fr:=i //else if bkt^.peer[i].addr=addr then fr:=i else if bkt^.peer[i].id=id then begin - if bkt^.peer[i].addr<>addr then continue; + if bkt^.peer[i].addr<>addr then exit; {found node in the bucket} //writeln('DHT: UpdateNode ',string(id)); // ?? bkt^.ModifyTime:=mNow; -- 2.11.4.GIT