From 1b7cc621db70bf6b63beeb42ab5732223a434497 Mon Sep 17 00:00:00 2001 From: Christian Ulrich Date: Sat, 10 Oct 2020 11:40:12 +0200 Subject: [PATCH] close punchd connection when app is about to quit --- examples/app/app.nim | 2 ++ 1 file changed, 2 insertions(+) diff --git a/examples/app/app.nim b/examples/app/app.nim index 3183cbf..c0f2e8c 100644 --- a/examples/app/app.nim +++ b/examples/app/app.nim @@ -245,6 +245,8 @@ proc runApp(serverHostname: string, serverPort: Port, peerId: string, let msg = await sock.recv(4) echo "received message: ", msg sock.close() + + punchdConn.sock.close() proc main() = if paramCount() < 3 or paramCount() > 4: