about summary refs log tree commit diff stats
path: root/src/loader
diff options
context:
space:
mode:
Diffstat (limited to 'src/loader')
-rw-r--r--src/loader/loader.nim1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/loader/loader.nim b/src/loader/loader.nim
index 5aed021e..295062b5 100644
--- a/src/loader/loader.nim
+++ b/src/loader/loader.nim
@@ -987,6 +987,7 @@ proc onConnected*(loader: FileLoader, fd: int) =
     r.sread(msg) # packet 1
     loader.unregisterFun(fd)
     loader.unregistered.add(fd)
+    stream.sclose()
     let err = newTypeError("NetworkError when attempting to fetch resource")
     promise.resolve(JSResult[Response].err(err))
   loader.connecting.del(fd)