mirror of
https://gitlab.torproject.org/tpo/core/tor.git
synced 2024-11-28 06:13:31 +01:00
- fixed up typos in eventdns.c
- configure lets user build with eventdns on win32 svn:r8332
This commit is contained in:
parent
5a8563baed
commit
91d7ad660f
@ -96,9 +96,6 @@ if test $bwin32 = true; then
|
||||
|
||||
AC_DEFINE(MS_WINDOWS,1, [Define to 1 if we are building for a Windows platform.])
|
||||
|
||||
if test $eventdns = true; then
|
||||
AC_MSG_ERROR([tor+eventdns not yet supported on Windows.])
|
||||
fi
|
||||
|
||||
fi
|
||||
|
||||
|
@ -450,11 +450,12 @@ inet_aton(const char *c, struct in_addr *addr)
|
||||
if (strcmp(c, "255.255.255.255") == 0) {
|
||||
addr->s_addr = 0xffffffffu;
|
||||
} else {
|
||||
uint32_t r = inet_addr(c);
|
||||
r = inet_addr(c);
|
||||
if (r == INADDR_NONE)
|
||||
return 0;
|
||||
addr->a_addr = r;
|
||||
addr->s_addr = r;
|
||||
}
|
||||
return 1;
|
||||
}
|
||||
#define CLOSE_SOCKET(x) closesocket(x)
|
||||
#else
|
||||
@ -2062,7 +2063,9 @@ load_nameservers_with_getnetworkparams(void)
|
||||
|
||||
if (!(handle = LoadLibrary("iphlpapi.dll")))
|
||||
goto done;
|
||||
if (!(fn = GetProcAddress(handle, "GetNetworkParams")))
|
||||
if (!(fn =
|
||||
(DWORD (WINAPI*)(FIXED_INFO*,DWORD*))
|
||||
GetProcAddress(handle, "GetNetworkParams")))
|
||||
goto done;
|
||||
|
||||
buf = malloc(size);
|
||||
@ -2084,12 +2087,12 @@ load_nameservers_with_getnetworkparams(void)
|
||||
|
||||
assert(fixed);
|
||||
added_any = 0;
|
||||
ns = fixed->DnsServerList;
|
||||
ns = &(fixed->DnsServerList);
|
||||
while (ns) {
|
||||
r = eventdns_nameserver_ip_add_line(ns->IpAddress.String);
|
||||
if (r) { status = r; goto done; }
|
||||
added_any = 0;
|
||||
ns = ns->next;
|
||||
ns = ns->Next;
|
||||
}
|
||||
|
||||
if (!added_any)
|
||||
|
Loading…
Reference in New Issue
Block a user