C# UDP 远程主机强制关闭了一个现有连接 解决方案
uint IOC_IN = 0x80000000; uint IOC_VENDOR = 0x18000000; uint SIO_UDP_CONNRESET = IOC_IN | IOC_VENDOR | 12; SocketClient.IOControl((int)SIO_UDP_CONNRESET, new byte[] { Convert.ToByte(false) }, null);
亲测有效!!!
原链接:https://blog.csdn.net/sunzhen6251/article/details/124168805