diff --git a/src/tun.c b/src/tun.c index 5a9017d..880f7ef 100644 --- a/src/tun.c +++ b/src/tun.c @@ -285,9 +285,12 @@ DWORD WINAPI tun_reader(LPVOID arg) int len; int res; OVERLAPPED olpd; + struct sockaddr_storage addr; + int addr_len; int sock; - sock = open_dns(0, INADDR_ANY); + addr_len = get_addr("127.0.0.1", 0, AF_INET, 0, &addr); + sock = open_dns(&addr, addr_len); olpd.hEvent = CreateEvent(NULL, TRUE, FALSE, NULL);