From 2de9c957704e09c2fba3ff80970e446c295adfe7 Mon Sep 17 00:00:00 2001 From: Kim De Mey Date: Wed, 21 Jun 2023 18:56:57 +0200 Subject: [PATCH] Remove a socket.close after destroy + bump nim-eth for uTP fixes (#1604) --- fluffy/network/wire/portal_protocol.nim | 5 ++++- vendor/nim-eth | 2 +- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/fluffy/network/wire/portal_protocol.nim b/fluffy/network/wire/portal_protocol.nim index 19ad21c50a..3b14d8b522 100644 --- a/fluffy/network/wire/portal_protocol.nim +++ b/fluffy/network/wire/portal_protocol.nim @@ -649,7 +649,10 @@ proc findContent*(p: PortalProtocol, dst: Node, contentKey: ByteList): else : debug "Socket read time-out", socketKey = socket.socketKey - socket.close() + # Note: This might look a bit strange, be not doing a socket.close() + # here as this is already done internally. utp_socket `checkTimeouts` + # already does a socket.destroy() on timeout. Might want to change the + # API on this later though. return err("Reading data from socket timed out, content request failed") except CancelledError as exc: # even though we already installed cancelCallback on readFut, it is worth diff --git a/vendor/nim-eth b/vendor/nim-eth index c608426d03..6dacb2ca5c 160000 --- a/vendor/nim-eth +++ b/vendor/nim-eth @@ -1 +1 @@ -Subproject commit c608426d03167ff44a90ab6864c3b57eddb5512d +Subproject commit 6dacb2ca5ce4e5528924f56c87620f38e1d0c0d4