mirror of
https://github.com/zerotier/ZeroTierOne.git
synced 2025-06-13 12:48:27 +00:00
Tap now basically sorta works on Windows. Now have to figure out how to control DHCP behavior since we normally don't want that.
This commit is contained in:
@ -167,14 +167,15 @@ UdpSocket::UdpSocket(
|
||||
|
||||
UdpSocket::~UdpSocket()
|
||||
{
|
||||
int s = _sock;
|
||||
#ifdef __WINDOWS__
|
||||
SOCKET s = _sock;
|
||||
_sock = INVALID_SOCKET;
|
||||
if (s != INVALID_SOCKET) {
|
||||
::shutdown(s,SD_BOTH);
|
||||
::closesocket(s);
|
||||
}
|
||||
#else
|
||||
int s = _sock;
|
||||
_sock = 0;
|
||||
if (s > 0) {
|
||||
::shutdown(s,SHUT_RDWR);
|
||||
|
Reference in New Issue
Block a user