mirror of
https://github.com/nim-lang/Nim.git
synced 2026-01-01 19:02:18 +00:00
nimsuggest: fix tcp socket leak for epc backend (#12384) [backport]
Same ase9fa4c9b9c, but for the epc backend which is used by emacs and vscode plugin. Since the EPC backend only deal with one connection per nimsuggest instance, only one socket is leaked, thus not as servere as with the tcp backend. (cherry picked from commitedb24b7ce0)
This commit is contained in:
@@ -353,7 +353,7 @@ proc replEpc(x: ThreadParams) {.thread.} =
|
||||
echo port
|
||||
stdout.flushFile()
|
||||
|
||||
var client = newSocket()
|
||||
var client: Socket
|
||||
# Wait for connection
|
||||
accept(server, client)
|
||||
while true:
|
||||
|
||||
Reference in New Issue
Block a user