How to get a specific socket and close it

前端 未结 3 1522
隐瞒了意图╮
隐瞒了意图╮ 2021-01-16 03:47

I want to close a socket so I can reopen one on the same port but I do not have a handle on that socket.

How can I get the socket that is listening on localhost:873

3条回答
  •  醉话见心
    2021-01-16 04:34

    Without a kernel driver this is not possible. It is not legal in Windows to grab a socket handle in another process and close it proactively.

提交回复
热议问题