From daa31f285d7d18c308b720b5b502d3683862f020 Mon Sep 17 00:00:00 2001 From: Christian Ulrich Date: Sun, 4 Oct 2020 11:43:46 +0200 Subject: [PATCH] close socket when we stop accepting --- tcp_syni.nim | 1 + 1 file changed, 1 insertion(+) diff --git a/tcp_syni.nim b/tcp_syni.nim index 0060ca0..4ca7381 100644 --- a/tcp_syni.nim +++ b/tcp_syni.nim @@ -258,6 +258,7 @@ proc doAccept(puncher: TcpSyniPuncher, srcIp: IpAddress, # FIXME: should attempts have timestamps, so we can decide here which ones to delete? if attempts.len() <= 1: break + sock.close() proc accept*(puncher: TcpSyniPuncher, srcPort: Port, dstIp: IpAddress, dstPorts: seq[Port],