Browse Source

Upgrade C-Ares to 1.7.3

v0.7.4-release
Ryan Dahl 15 years ago
parent
commit
9c85357846
  1. 25
      deps/c-ares/CHANGES
  2. 2
      deps/c-ares/README
  3. 1
      deps/c-ares/README.msvc
  4. 2
      deps/c-ares/README.node
  5. 14
      deps/c-ares/RELEASE-NOTES
  6. 1
      deps/c-ares/ares.h
  7. 1
      deps/c-ares/ares__close_sockets.c
  8. 1
      deps/c-ares/ares__get_hostent.c
  9. 1
      deps/c-ares/ares__read_line.c
  10. 1
      deps/c-ares/ares__timeval.c
  11. 1
      deps/c-ares/ares_cancel.c
  12. 1
      deps/c-ares/ares_data.c
  13. 1
      deps/c-ares/ares_data.h
  14. 1
      deps/c-ares/ares_destroy.c
  15. 1
      deps/c-ares/ares_dns.h
  16. 1
      deps/c-ares/ares_expand_name.c
  17. 1
      deps/c-ares/ares_expand_string.c
  18. 1
      deps/c-ares/ares_fds.c
  19. 1
      deps/c-ares/ares_free_hostent.c
  20. 1
      deps/c-ares/ares_free_string.c
  21. 11
      deps/c-ares/ares_gethostbyaddr.c
  22. 34
      deps/c-ares/ares_gethostbyname.c
  23. 35
      deps/c-ares/ares_getnameinfo.c
  24. 1
      deps/c-ares/ares_getopt.c
  25. 1
      deps/c-ares/ares_getsock.c
  26. 15
      deps/c-ares/ares_init.c
  27. 1
      deps/c-ares/ares_ipv6.h
  28. 1
      deps/c-ares/ares_library_init.c
  29. 1
      deps/c-ares/ares_library_init.h
  30. 1
      deps/c-ares/ares_llist.c
  31. 1
      deps/c-ares/ares_llist.h
  32. 1
      deps/c-ares/ares_mkquery.c
  33. 1
      deps/c-ares/ares_nowarn.c
  34. 1
      deps/c-ares/ares_nowarn.h
  35. 1
      deps/c-ares/ares_options.c
  36. 1
      deps/c-ares/ares_parse_a_reply.c
  37. 1
      deps/c-ares/ares_parse_aaaa_reply.c
  38. 1
      deps/c-ares/ares_parse_ptr_reply.c
  39. 1
      deps/c-ares/ares_parse_srv_reply.c
  40. 1
      deps/c-ares/ares_parse_txt_reply.c
  41. 1
      deps/c-ares/ares_private.h
  42. 3
      deps/c-ares/ares_process.c
  43. 1
      deps/c-ares/ares_query.c
  44. 1
      deps/c-ares/ares_rules.h
  45. 1
      deps/c-ares/ares_search.c
  46. 1
      deps/c-ares/ares_send.c
  47. 1
      deps/c-ares/ares_strcasecmp.c
  48. 1
      deps/c-ares/ares_strcasecmp.h
  49. 1
      deps/c-ares/ares_strdup.c
  50. 1
      deps/c-ares/ares_strdup.h
  51. 1
      deps/c-ares/ares_strerror.c
  52. 1
      deps/c-ares/ares_timeout.c
  53. 1
      deps/c-ares/ares_version.c
  54. 5
      deps/c-ares/ares_version.h
  55. 1
      deps/c-ares/ares_writev.c
  56. 1
      deps/c-ares/ares_writev.h
  57. 1
      deps/c-ares/bitncmp.c
  58. 1
      deps/c-ares/bitncmp.h
  59. 353
      deps/c-ares/config-win32.h
  60. 1
      deps/c-ares/get_ver.awk
  61. 1
      deps/c-ares/inet_net_pton.c
  62. 1
      deps/c-ares/inet_net_pton.h
  63. 1
      deps/c-ares/inet_ntop.c
  64. 1
      deps/c-ares/inet_ntop.h
  65. 1
      deps/c-ares/nameser.h
  66. 58
      deps/c-ares/setup_once.h
  67. 1
      deps/c-ares/windows_port.c

25
deps/c-ares/CHANGES

@ -1,7 +1,30 @@
Changelog for the c-ares project
Version 1.7.3 (June 11, 2010)
Fixed:
o builds on Android
o now includes all files necessary to build it (1.7.2 lacked a file)
Version 1.7.2 (June 10, 2010)
Changed:
o Added ares_parse_mx_reply()
Fixed:
o ares_init: Last, not first instance of domain or search should win
o improve alternative definition of bool
o fix VS2010 compiler warnings
Version 1.7.1 (Mar 23, 2010)
* May 31, 2010 (Jakub Hrozek)
- Use the last instance of domain/search, not the first one
* March 23, 2010 (Daniel Stenberg)
- We switched from CVS to git. See http://github.com/bagder/c-ares
@ -27,7 +50,7 @@ Version 1.7.1 (Mar 23, 2010)
functions do not support IPv6 name servers. This implies that if the user
is capable of defining or providing an IPv6 name server, and the app is
using ares_init_options() or ares_save_options() at some point to handle
the name servers, the app will likely loose IPv6 name servers.
the name servers, the app will likely lose IPv6 name servers.
* January 28, 2010 (Daniel Stenberg)
- Tommie Gannert pointed out a silly bug in ares_process_fd() since it didn't

2
deps/c-ares/README

@ -44,7 +44,7 @@ The following notes apply to c-ares version 1.7.0 and later.
* If you intend to distribute an already compiled c-ares library you _MUST_
also distribute along with it the generated ares_build.h which has been
used to compile it. Otherwise the library will be of no use for the users of
the library that you have built. It is _your_ responsability to provide this
the library that you have built. It is _your_ responsibility to provide this
file. No one at the c-ares project can know how you have built the library.
* File ares_build.h includes platform and configuration dependent info,

1
deps/c-ares/README.msvc

@ -1,4 +1,3 @@
$Id$
___ __ _ _ __ ___ ___

2
deps/c-ares/README.node

@ -1,6 +1,6 @@
Library: c-ares, DNS resolver
Version: 1.7.1 (23 march, 2010)
Version: 1.7.3 (11 June, 2010)
Authors: Greg Hudson, Daniel Stenberg

14
deps/c-ares/RELEASE-NOTES

@ -1,18 +1,12 @@
This is what's new and changed in the c-ares 1.7.1 release:
Changed:
o added IPv6 name servers support
c-ares version 1.7.3
Fixed:
o closing of sockets on Windows systems
o MSVC deprecated compiler options warnings
o ares_process_fd() didn't check broken connections
o builds on Android
o now includes all files necessary to build it (1.7.2 lacked a file)
Thanks go to these friendly people for their efforts and contributions:
Ingmar Runge, Laszlo Tamas Szabo, Yang Tse, Tommie Gannert, Gregor Jasny,
Phil Blundell, Cedric Bail, Jakub Hrozek
Yang Tse, Bogdan Vatra
Have fun!

1
deps/c-ares/ares.h

@ -1,4 +1,3 @@
/* $Id$ */
/* Copyright 1998, 2009 by the Massachusetts Institute of Technology.
* Copyright (C) 2007-2010 by Daniel Stenberg

1
deps/c-ares/ares__close_sockets.c

@ -1,4 +1,3 @@
/* $Id$ */
/* Copyright 1998 by the Massachusetts Institute of Technology.
*

1
deps/c-ares/ares__get_hostent.c

@ -1,4 +1,3 @@
/* $Id$ */
/* Copyright 1998, 2010 by the Massachusetts Institute of Technology.
*

1
deps/c-ares/ares__read_line.c

@ -1,4 +1,3 @@
/* $Id$ */
/* Copyright 1998 by the Massachusetts Institute of Technology.
*

1
deps/c-ares/ares__timeval.c

@ -1,4 +1,3 @@
/* $Id$ */
/* Copyright (C) 2008 by Daniel Stenberg et al
*

1
deps/c-ares/ares_cancel.c

@ -1,4 +1,3 @@
/* $Id$ */
/* Copyright (C) 2004 by Daniel Stenberg et al
*

1
deps/c-ares/ares_data.c

@ -1,4 +1,3 @@
/* $Id$ */
/* Copyright (C) 2009-2010 by Daniel Stenberg
*

1
deps/c-ares/ares_data.h

@ -1,4 +1,3 @@
/* $Id$ */
/* Copyright (C) 2009-2010 by Daniel Stenberg
*

1
deps/c-ares/ares_destroy.c

@ -1,4 +1,3 @@
/* $Id$ */
/* Copyright 1998 by the Massachusetts Institute of Technology.
* Copyright (C) 2004-2010 by Daniel Stenberg

1
deps/c-ares/ares_dns.h

@ -1,4 +1,3 @@
/* $Id$ */
/* Copyright 1998 by the Massachusetts Institute of Technology.
*

1
deps/c-ares/ares_expand_name.c

@ -1,4 +1,3 @@
/* $Id$ */
/* Copyright 1998 by the Massachusetts Institute of Technology.
*

1
deps/c-ares/ares_expand_string.c

@ -1,4 +1,3 @@
/* $Id$ */
/* Copyright 1998 by the Massachusetts Institute of Technology.
*

1
deps/c-ares/ares_fds.c

@ -1,4 +1,3 @@
/* $Id$ */
/* Copyright 1998 by the Massachusetts Institute of Technology.
*

1
deps/c-ares/ares_free_hostent.c

@ -1,4 +1,3 @@
/* $Id$ */
/* Copyright 1998 by the Massachusetts Institute of Technology.
*

1
deps/c-ares/ares_free_string.c

@ -1,4 +1,3 @@
/* $Id$ */
/* Copyright 2000 by the Massachusetts Institute of Technology.
*

11
deps/c-ares/ares_gethostbyaddr.c

@ -1,4 +1,3 @@
/* $Id$ */
/* Copyright 1998 by the Massachusetts Institute of Technology.
*
@ -191,8 +190,8 @@ static int file_lookup(struct ares_addr *addr, struct hostent **host)
char tmp[MAX_PATH];
HKEY hkeyHosts;
if (RegOpenKeyEx(HKEY_LOCAL_MACHINE, WIN_NS_NT_KEY, 0, KEY_READ, &hkeyHosts)
== ERROR_SUCCESS)
if (RegOpenKeyEx(HKEY_LOCAL_MACHINE, WIN_NS_NT_KEY, 0, KEY_READ,
&hkeyHosts) == ERROR_SUCCESS)
{
DWORD dwLength = MAX_PATH;
RegQueryValueEx(hkeyHosts, DATABASEPATH, NULL, NULL, (LPBYTE)tmp,
@ -241,12 +240,14 @@ static int file_lookup(struct ares_addr *addr, struct hostent **host)
}
if (addr->family == AF_INET)
{
if (memcmp((*host)->h_addr, &addr->addrV4, sizeof(addr->addrV4)) == 0)
if (memcmp((*host)->h_addr, &addr->addrV4,
sizeof(addr->addrV4)) == 0)
break;
}
else if (addr->family == AF_INET6)
{
if (memcmp((*host)->h_addr, &addr->addrV6, sizeof(addr->addrV6)) == 0)
if (memcmp((*host)->h_addr, &addr->addrV6,
sizeof(addr->addrV6)) == 0)
break;
}
ares_free_hostent(*host);

34
deps/c-ares/ares_gethostbyname.c

@ -1,4 +1,3 @@
/* $Id$ */
/* Copyright 1998 by the Massachusetts Institute of Technology.
*
@ -151,8 +150,8 @@ static void next_lookup(struct host_query *hquery, int status_code)
}
else {
hquery->sent_family = AF_INET;
ares_search(hquery->channel, hquery->name, C_IN, T_A, host_callback,
hquery);
ares_search(hquery->channel, hquery->name, C_IN, T_A,
host_callback, hquery);
}
return;
@ -195,9 +194,10 @@ static void host_callback(void *arg, int status, int timeouts,
{
status = ares_parse_aaaa_reply(abuf, alen, &host, NULL, NULL);
if (status == ARES_ENODATA || status == ARES_EBADRESP) {
/* The query returned something but either there were no AAAA records (e.g. just CNAME)
or the response was malformed. Try looking up A instead.
We should possibly limit this attempt-next logic to AF_UNSPEC lookups only. */
/* The query returned something but either there were no AAAA
records (e.g. just CNAME) or the response was malformed. Try
looking up A instead. We should possibly limit this
attempt-next logic to AF_UNSPEC lookups only. */
hquery->sent_family = AF_INET;
ares_search(hquery->channel, hquery->name, C_IN, T_A,
host_callback, hquery);
@ -208,10 +208,12 @@ static void host_callback(void *arg, int status, int timeouts,
}
end_hquery(hquery, status, host);
}
else if ((status == ARES_ENODATA || status == ARES_EBADRESP || status == ARES_ETIMEOUT) && hquery->sent_family == AF_INET6)
else if ((status == ARES_ENODATA || status == ARES_EBADRESP ||
status == ARES_ETIMEOUT) && hquery->sent_family == AF_INET6)
{
/* The AAAA query yielded no useful result. Now look up an A instead.
We should possibly limit this attempt-next logic to AF_UNSPEC lookups only. */
We should possibly limit this attempt-next logic to AF_UNSPEC lookups
only. */
hquery->sent_family = AF_INET;
ares_search(hquery->channel, hquery->name, C_IN, T_A, host_callback,
hquery);
@ -235,8 +237,8 @@ static void end_hquery(struct host_query *hquery, int status,
/* If the name looks like an IP address, fake up a host entry, end the
* query immediately, and return true. Otherwise return false.
*/
static int fake_hostent(const char *name, int family, ares_host_callback callback,
void *arg)
static int fake_hostent(const char *name, int family,
ares_host_callback callback, void *arg)
{
struct hostent hostent;
char *aliases[1] = { NULL };
@ -346,8 +348,8 @@ static int file_lookup(const char *name, int family, struct hostent **host)
char tmp[MAX_PATH];
HKEY hkeyHosts;
if (RegOpenKeyEx(HKEY_LOCAL_MACHINE, WIN_NS_NT_KEY, 0, KEY_READ, &hkeyHosts)
== ERROR_SUCCESS)
if (RegOpenKeyEx(HKEY_LOCAL_MACHINE, WIN_NS_NT_KEY, 0, KEY_READ,
&hkeyHosts) == ERROR_SUCCESS)
{
DWORD dwLength = MAX_PATH;
RegQueryValueEx(hkeyHosts, DATABASEPATH, NULL, NULL, (LPBYTE)tmp,
@ -408,8 +410,8 @@ static int file_lookup(const char *name, int family, struct hostent **host)
return status;
}
static void sort_addresses(struct hostent *host, const struct apattern *sortlist,
int nsort)
static void sort_addresses(struct hostent *host,
const struct apattern *sortlist, int nsort)
{
struct in_addr a1, a2;
int i1, i2, ind1, ind2;
@ -464,8 +466,8 @@ static int get_address_index(const struct in_addr *addr,
return i;
}
static void sort6_addresses(struct hostent *host, const struct apattern *sortlist,
int nsort)
static void sort6_addresses(struct hostent *host,
const struct apattern *sortlist, int nsort)
{
struct ares_in6_addr a1, a2;
int i1, i2, ind1, ind2;

35
deps/c-ares/ares_getnameinfo.c

@ -1,4 +1,3 @@
/* $Id$ */
/* Copyright 2005 by Dominick Meglio
*
@ -81,7 +80,8 @@ struct nameinfo_query {
(sizeof("ffff:ffff:ffff:ffff:ffff:ffff:255.255.255.255"))
#endif
static void nameinfo_callback(void *arg, int status, int timeouts, struct hostent *host);
static void nameinfo_callback(void *arg, int status, int timeouts,
struct hostent *host);
static char *lookup_service(unsigned short port, int flags,
char *buf, size_t buflen);
#ifdef HAVE_SOCKADDR_IN6_SIN6_SCOPE_ID
@ -202,7 +202,8 @@ void ares_getnameinfo(ares_channel channel, const struct sockaddr *sa,
}
}
static void nameinfo_callback(void *arg, int status, int timeouts, struct hostent *host)
static void nameinfo_callback(void *arg, int status, int timeouts,
struct hostent *host)
{
struct nameinfo_query *niquery = (struct nameinfo_query *) arg;
char srvbuf[33];
@ -221,8 +222,8 @@ static void nameinfo_callback(void *arg, int status, int timeouts, struct hosten
service = lookup_service(niquery->addr.addr6.sin6_port,
niquery->flags, srvbuf, sizeof(srvbuf));
}
/* NOFQDN means we have to strip off the domain name portion.
We do this by determining our own domain name, then searching the string
/* NOFQDN means we have to strip off the domain name portion. We do
this by determining our own domain name, then searching the string
for this domain name and removing it.
*/
#ifdef HAVE_GETHOSTNAME
@ -239,7 +240,8 @@ static void nameinfo_callback(void *arg, int status, int timeouts, struct hosten
}
}
#endif
niquery->callback(niquery->arg, ARES_SUCCESS, niquery->timeouts, (char *)(host->h_name),
niquery->callback(niquery->arg, ARES_SUCCESS, niquery->timeouts,
(char *)(host->h_name),
service);
return;
}
@ -248,12 +250,15 @@ static void nameinfo_callback(void *arg, int status, int timeouts, struct hosten
{
char ipbuf[IPBUFSIZ];
if (niquery->family == AF_INET)
ares_inet_ntop(AF_INET, &niquery->addr.addr4.sin_addr, ipbuf, IPBUFSIZ);
ares_inet_ntop(AF_INET, &niquery->addr.addr4.sin_addr, ipbuf,
IPBUFSIZ);
else
{
ares_inet_ntop(AF_INET6, &niquery->addr.addr6.sin6_addr, ipbuf, IPBUFSIZ);
ares_inet_ntop(AF_INET6, &niquery->addr.addr6.sin6_addr, ipbuf,
IPBUFSIZ);
#ifdef HAVE_SOCKADDR_IN6_SIN6_SCOPE_ID
append_scopeid(&niquery->addr.addr6, niquery->flags, ipbuf, sizeof(ipbuf));
append_scopeid(&niquery->addr.addr6, niquery->flags, ipbuf,
sizeof(ipbuf));
#endif
}
/* They want a service too */
@ -266,7 +271,8 @@ static void nameinfo_callback(void *arg, int status, int timeouts, struct hosten
service = lookup_service(niquery->addr.addr6.sin6_port,
niquery->flags, srvbuf, sizeof(srvbuf));
}
niquery->callback(niquery->arg, ARES_SUCCESS, niquery->timeouts, ipbuf, service);
niquery->callback(niquery->arg, ARES_SUCCESS, niquery->timeouts, ipbuf,
service);
return;
}
niquery->callback(niquery->arg, status, niquery->timeouts, NULL, NULL);
@ -301,10 +307,12 @@ static char *lookup_service(unsigned short port, int flags,
sep = &se;
memset(tmpbuf, 0, sizeof(tmpbuf));
#if GETSERVBYPORT_R_ARGS == 6
if (getservbyport_r(port, proto, &se, (void *)tmpbuf, sizeof(tmpbuf), &sep) != 0)
if (getservbyport_r(port, proto, &se, (void *)tmpbuf,
sizeof(tmpbuf), &sep) != 0)
sep = NULL;
#elif GETSERVBYPORT_R_ARGS == 5
sep = getservbyport_r(port, proto, &se, (void *)tmpbuf, sizeof(tmpbuf));
sep = getservbyport_r(port, proto, &se, (void *)tmpbuf,
sizeof(tmpbuf));
#elif GETSERVBYPORT_R_ARGS == 4
if (getservbyport_r(port, proto, &se, (void *)tmpbuf) != 0)
sep = NULL;
@ -350,7 +358,8 @@ static void append_scopeid(struct sockaddr_in6 *addr6, unsigned int flags,
char fmt_lu[] = "%lu";
char tmpbuf[IF_NAMESIZE + 2];
size_t bufl;
char *fmt = (sizeof(addr6->sin6_scope_id) > sizeof(unsigned int))?fmt_lu:fmt_u;
char *fmt = (sizeof(addr6->sin6_scope_id) > sizeof(unsigned int))?
fmt_lu:fmt_u;
tmpbuf[0] = '%';

1
deps/c-ares/ares_getopt.c

@ -3,7 +3,6 @@
* on 2007-04-11. Lifted from version 5.2 of the 'Open Mash' project with
* the modified BSD license, BSD license without the advertising clause.
*
* $Id$
*/
/*

1
deps/c-ares/ares_getsock.c

@ -1,4 +1,3 @@
/* $Id$ */
/* Copyright (C) 2005 - 2010, Daniel Stenberg
*

15
deps/c-ares/ares_init.c

@ -1,4 +1,3 @@
/* $Id$ */
/* Copyright 1998 by the Massachusetts Institute of Technology.
* Copyright (C) 2007-2010 by Daniel Stenberg
@ -70,6 +69,10 @@
#include "ares_library_init.h"
#include "ares_private.h"
#ifdef ANDROID
#include <sys/system_properties.h>
#endif
#ifdef WATT32
#undef WIN32 /* Redefined in MingW/MSVC headers */
#endif
@ -825,6 +828,12 @@ DhcpNameServer
servers[i].addr.addrV4.s_addr = htonl(def_nameservers[i]);
status = ARES_EOF;
#elif defined(ANDROID)
char value[PROP_VALUE_MAX]="";
__system_property_get("net.dns1", value);
status = config_nameserver(&servers, &nservers, value);
if (status == ARES_SUCCESS)
status = ARES_EOF;
#else
{
char *p;
@ -840,11 +849,11 @@ DhcpNameServer
if (fp) {
while ((status = ares__read_line(fp, &line, &linesize)) == ARES_SUCCESS)
{
if ((p = try_config(line, "domain")) && channel->ndomains == -1)
if ((p = try_config(line, "domain")))
status = config_domain(channel, p);
else if ((p = try_config(line, "lookup")) && !channel->lookups)
status = config_lookup(channel, p, "bind", "file");
else if ((p = try_config(line, "search")) && channel->ndomains == -1)
else if ((p = try_config(line, "search")))
status = set_search(channel, p);
else if ((p = try_config(line, "nameserver")) && channel->nservers == -1)
status = config_nameserver(&servers, &nservers, p);

1
deps/c-ares/ares_ipv6.h

@ -1,4 +1,3 @@
/* $Id$ */
/* Copyright (C) 2005 by Dominick Meglio
*

1
deps/c-ares/ares_library_init.c

@ -1,4 +1,3 @@
/* $Id$ */
/* Copyright 1998 by the Massachusetts Institute of Technology.
* Copyright (C) 2004-2009 by Daniel Stenberg

1
deps/c-ares/ares_library_init.h

@ -1,7 +1,6 @@
#ifndef HEADER_CARES_LIBRARY_INIT_H
#define HEADER_CARES_LIBRARY_INIT_H
/* $Id$ */
/* Copyright 1998 by the Massachusetts Institute of Technology.
* Copyright (C) 2004-2009 by Daniel Stenberg

1
deps/c-ares/ares_llist.c

@ -1,4 +1,3 @@
/* $Id$ */
/* Copyright 1998 by the Massachusetts Institute of Technology.
*

1
deps/c-ares/ares_llist.h

@ -1,7 +1,6 @@
#ifndef __ARES_LLIST_H
#define __ARES_LLIST_H
/* $Id$ */
/* Copyright 1998 by the Massachusetts Institute of Technology.
*

1
deps/c-ares/ares_mkquery.c

@ -1,4 +1,3 @@
/* $Id$ */
/* Copyright 1998 by the Massachusetts Institute of Technology.
*

1
deps/c-ares/ares_nowarn.c

@ -1,4 +1,3 @@
/* $Id$ */
/* Copyright (C) 2010 by Daniel Stenberg
*

1
deps/c-ares/ares_nowarn.h

@ -1,7 +1,6 @@
#ifndef HEADER_CARES_NOWARN_H
#define HEADER_CARES_NOWARN_H
/* $Id$ */
/* Copyright (C) 2010 by Daniel Stenberg
*

1
deps/c-ares/ares_options.c

@ -1,4 +1,3 @@
/* $Id$ */
/* Copyright 1998 by the Massachusetts Institute of Technology.
* Copyright (C) 2008-2010 by Daniel Stenberg

1
deps/c-ares/ares_parse_a_reply.c

@ -1,4 +1,3 @@
/* $Id$ */
/* Copyright 1998 by the Massachusetts Institute of Technology.
*

1
deps/c-ares/ares_parse_aaaa_reply.c

@ -1,4 +1,3 @@
/* $Id$ */
/* Copyright 1998 by the Massachusetts Institute of Technology.
* Copyright 2005 Dominick Meglio

1
deps/c-ares/ares_parse_ptr_reply.c

@ -1,4 +1,3 @@
/* $Id$ */
/* Copyright 1998 by the Massachusetts Institute of Technology.
*

1
deps/c-ares/ares_parse_srv_reply.c

@ -1,4 +1,3 @@
/* $Id$ */
/* Copyright 1998 by the Massachusetts Institute of Technology.
* Copyright (C) 2009 by Jakub Hrozek <jhrozek@redhat.com>

1
deps/c-ares/ares_parse_txt_reply.c

@ -1,4 +1,3 @@
/* $Id$ */
/* Copyright 1998 by the Massachusetts Institute of Technology.
* Copyright (C) 2009 by Jakub Hrozek <jhrozek@redhat.com>

1
deps/c-ares/ares_private.h

@ -1,7 +1,6 @@
#ifndef __ARES_PRIVATE_H
#define __ARES_PRIVATE_H
/* $Id$ */
/* Copyright 1998 by the Massachusetts Institute of Technology.
* Copyright (C) 2004-2010 by Daniel Stenberg

3
deps/c-ares/ares_process.c

@ -1,4 +1,3 @@
/* $Id$ */
/* Copyright 1998 by the Massachusetts Institute of Technology.
* Copyright (C) 2004-2010 by Daniel Stenberg
@ -948,7 +947,7 @@ static int open_tcp_socket(ares_channel channel, struct server_state *server)
* Disable the Nagle algorithm (only relevant for TCP sockets, and thus not
* in configure_socket). In general, in DNS lookups we're pretty much
* interested in firing off a single request and then waiting for a reply,
* so batching isn't very interesting in general.
* so batching isn't very interesting.
*/
opt = 1;
if (setsockopt(s, IPPROTO_TCP, TCP_NODELAY,

1
deps/c-ares/ares_query.c

@ -1,4 +1,3 @@
/* $Id$ */
/* Copyright 1998 by the Massachusetts Institute of Technology.
*

1
deps/c-ares/ares_rules.h

@ -1,7 +1,6 @@
#ifndef __CARES_RULES_H
#define __CARES_RULES_H
/* $Id$ */
/* Copyright (C) 2009 by Daniel Stenberg et al
*

1
deps/c-ares/ares_search.c

@ -1,4 +1,3 @@
/* $Id$ */
/* Copyright 1998 by the Massachusetts Institute of Technology.
*

1
deps/c-ares/ares_send.c

@ -1,4 +1,3 @@
/* $Id$ */
/* Copyright 1998 by the Massachusetts Institute of Technology.
*

1
deps/c-ares/ares_strcasecmp.c

@ -1,5 +1,4 @@
/* $Id$ */
/* Copyright 1998 by the Massachusetts Institute of Technology.
*

1
deps/c-ares/ares_strcasecmp.h

@ -1,7 +1,6 @@
#ifndef HEADER_CARES_STRCASECMP_H
#define HEADER_CARES_STRCASECMP_H
/* $Id$ */
/* Copyright 1998 by the Massachusetts Institute of Technology.
*

1
deps/c-ares/ares_strdup.c

@ -1,5 +1,4 @@
/* $Id$ */
/* Copyright 1998 by the Massachusetts Institute of Technology.
*

1
deps/c-ares/ares_strdup.h

@ -1,7 +1,6 @@
#ifndef HEADER_CARES_STRDUP_H
#define HEADER_CARES_STRDUP_H
/* $Id$ */
/* Copyright 1998 by the Massachusetts Institute of Technology.
*

1
deps/c-ares/ares_strerror.c

@ -1,4 +1,3 @@
/* $Id$ */
/* Copyright 1998 by the Massachusetts Institute of Technology.
*

1
deps/c-ares/ares_timeout.c

@ -1,4 +1,3 @@
/* $Id$ */
/* Copyright 1998 by the Massachusetts Institute of Technology.
*

1
deps/c-ares/ares_version.c

@ -1,4 +1,3 @@
/* $Id$ */
#include "ares_setup.h"
#include "ares.h"

5
deps/c-ares/ares_version.h

@ -1,15 +1,14 @@
/* $Id$ */
#ifndef ARES__VERSION_H
#define ARES__VERSION_H
#define ARES_VERSION_MAJOR 1
#define ARES_VERSION_MINOR 7
#define ARES_VERSION_PATCH 1
#define ARES_VERSION_PATCH 3
#define ARES_VERSION ((ARES_VERSION_MAJOR<<16)|\
(ARES_VERSION_MINOR<<8)|\
(ARES_VERSION_PATCH))
#define ARES_VERSION_STR "1.7.1"
#define ARES_VERSION_STR "1.7.3"
#if (ARES_VERSION >= 0x010700)
# define CARES_HAVE_ARES_LIBRARY_INIT 1

1
deps/c-ares/ares_writev.c

@ -1,5 +1,4 @@
/* $Id$ */
/* Copyright 1998 by the Massachusetts Institute of Technology.
*

1
deps/c-ares/ares_writev.h

@ -1,7 +1,6 @@
#ifndef HEADER_CARES_WRITEV_H
#define HEADER_CARES_WRITEV_H
/* $Id$ */
/* Copyright 1998 by the Massachusetts Institute of Technology.
*

1
deps/c-ares/bitncmp.c

@ -1,4 +1,3 @@
/* $Id$ */
/*
* Copyright (c) 2004 by Internet Systems Consortium, Inc. ("ISC")

1
deps/c-ares/bitncmp.h

@ -1,7 +1,6 @@
#ifndef __ARES_BITNCMP_H
#define __ARES_BITNCMP_H
/* $Id$ */
/* Copyright (C) 2005 by Dominick Meglio
*

353
deps/c-ares/config-win32.h

@ -0,0 +1,353 @@
#ifndef __ARES_CONFIG_WIN32_H
#define __ARES_CONFIG_WIN32_H
/* Copyright (C) 2004 - 2008 by Daniel Stenberg et al
*
* Permission to use, copy, modify, and distribute this software and its
* documentation for any purpose and without fee is hereby granted, provided
* that the above copyright notice appear in all copies and that both that
* copyright notice and this permission notice appear in supporting
* documentation, and that the name of M.I.T. not be used in advertising or
* publicity pertaining to distribution of the software without specific,
* written prior permission. M.I.T. makes no representations about the
* suitability of this software for any purpose. It is provided "as is"
* without express or implied warranty.
*/
/* ================================================================ */
/* ares/config-win32.h - Hand crafted config file for Windows */
/* ================================================================ */
/* ---------------------------------------------------------------- */
/* HEADER FILES */
/* ---------------------------------------------------------------- */
/* Define if you have the <getopt.h> header file. */
#if defined(__MINGW32__) || defined(__POCC__)
#define HAVE_GETOPT_H 1
#endif
/* Define if you have the <limits.h> header file. */
#define HAVE_LIMITS_H 1
/* Define if you have the <process.h> header file. */
#ifndef __SALFORDC__
#define HAVE_PROCESS_H 1
#endif
/* Define if you have the <signal.h> header file. */
#define HAVE_SIGNAL_H 1
/* Define if you have the <sys/time.h> header file */
/* #define HAVE_SYS_TIME_H 1 */
/* Define if you have the <time.h> header file. */
#define HAVE_TIME_H 1
/* Define if you have the <unistd.h> header file. */
#if defined(__MINGW32__) || defined(__WATCOMC__) || defined(__LCC__) || \
defined(__POCC__)
#define HAVE_UNISTD_H 1
#endif
/* Define if you have the <windows.h> header file. */
#define HAVE_WINDOWS_H 1
/* Define if you have the <winsock.h> header file. */
#define HAVE_WINSOCK_H 1
/* Define if you have the <winsock2.h> header file. */
#ifndef __SALFORDC__
#define HAVE_WINSOCK2_H 1
#endif
/* Define if you have the <ws2tcpip.h> header file. */
#ifndef __SALFORDC__
#define HAVE_WS2TCPIP_H 1
#endif
/* ---------------------------------------------------------------- */
/* OTHER HEADER INFO */
/* ---------------------------------------------------------------- */
/* Define if sig_atomic_t is an available typedef. */
#define HAVE_SIG_ATOMIC_T 1
/* Define if you have the ANSI C header files. */
#define STDC_HEADERS 1
/* Define if you can safely include both <sys/time.h> and <time.h>. */
/* #define TIME_WITH_SYS_TIME 1 */
/* ---------------------------------------------------------------- */
/* FUNCTIONS */
/* ---------------------------------------------------------------- */
/* Define if you have the closesocket function. */
#define HAVE_CLOSESOCKET 1
/* Define if you have the gethostname function. */
#define HAVE_GETHOSTNAME 1
/* Define if you have the ioctlsocket function. */
#define HAVE_IOCTLSOCKET 1
/* Define if you have a working ioctlsocket FIONBIO function. */
#define HAVE_IOCTLSOCKET_FIONBIO 1
/* Define if you have the strcasecmp function. */
/* #define HAVE_STRCASECMP 1 */
/* Define if you have the strdup function. */
#define HAVE_STRDUP 1
/* Define if you have the stricmp function. */
#define HAVE_STRICMP 1
/* Define if you have the strncasecmp function. */
/* #define HAVE_STRNCASECMP 1 */
/* Define if you have the strnicmp function. */
#define HAVE_STRNICMP 1
/* Define if you have the recv function. */
#define HAVE_RECV 1
/* Define to the type of arg 1 for recv. */
#define RECV_TYPE_ARG1 SOCKET
/* Define to the type of arg 2 for recv. */
#define RECV_TYPE_ARG2 char *
/* Define to the type of arg 3 for recv. */
#define RECV_TYPE_ARG3 int
/* Define to the type of arg 4 for recv. */
#define RECV_TYPE_ARG4 int
/* Define to the function return type for recv. */
#define RECV_TYPE_RETV int
/* Define if you have the recvfrom function. */
#define HAVE_RECVFROM 1
/* Define to the type of arg 1 for recvfrom. */
#define RECVFROM_TYPE_ARG1 SOCKET
/* Define to the type pointed by arg 2 for recvfrom. */
#define RECVFROM_TYPE_ARG2 char
/* Define to the type of arg 3 for recvfrom. */
#define RECVFROM_TYPE_ARG3 int
/* Define to the type of arg 4 for recvfrom. */
#define RECVFROM_TYPE_ARG4 int
/* Define to the type pointed by arg 5 for recvfrom. */
#define RECVFROM_TYPE_ARG5 struct sockaddr
/* Define to the type pointed by arg 6 for recvfrom. */
#define RECVFROM_TYPE_ARG6 int
/* Define to the function return type for recvfrom. */
#define RECVFROM_TYPE_RETV int
/* Define if you have the send function. */
#define HAVE_SEND 1
/* Define to the type of arg 1 for send. */
#define SEND_TYPE_ARG1 SOCKET
/* Define to the type qualifier of arg 2 for send. */
#define SEND_QUAL_ARG2 const
/* Define to the type of arg 2 for send. */
#define SEND_TYPE_ARG2 char *
/* Define to the type of arg 3 for send. */
#define SEND_TYPE_ARG3 int
/* Define to the type of arg 4 for send. */
#define SEND_TYPE_ARG4 int
/* Define to the function return type for send. */
#define SEND_TYPE_RETV int
/* Specifics for the Watt-32 tcp/ip stack */
#ifdef WATT32
#define SOCKET int
#define NS_INADDRSZ 4
#define HAVE_ARPA_NAMESER_H 1
#define HAVE_ARPA_INET_H 1
#define HAVE_NETDB_H 1
#define HAVE_NETINET_IN_H 1
#define HAVE_SYS_SOCKET_H 1
#define HAVE_NETINET_TCP_H 1
#define HAVE_AF_INET6 1
#define HAVE_PF_INET6 1
#define HAVE_STRUCT_IN6_ADDR 1
#define HAVE_STRUCT_SOCKADDR_IN6 1
#undef HAVE_WINSOCK_H
#undef HAVE_WINSOCK2_H
#undef HAVE_WS2TCPIP_H
#endif
/* ---------------------------------------------------------------- */
/* TYPEDEF REPLACEMENTS */
/* ---------------------------------------------------------------- */
/* Define this if in_addr_t is not an available 'typedefed' type */
#define in_addr_t unsigned long
/* Define as the return type of signal handlers (int or void). */
#define RETSIGTYPE void
/* Define ssize_t if it is not an available 'typedefed' type */
#ifndef _SSIZE_T_DEFINED
# if (defined(__WATCOMC__) && (__WATCOMC__ >= 1240)) || \
defined(__POCC__) || \
defined(__MINGW32__)
# elif defined(_WIN64)
# define _SSIZE_T_DEFINED
# define ssize_t __int64
# else
# define _SSIZE_T_DEFINED
# define ssize_t int
# endif
#endif
/* ---------------------------------------------------------------- */
/* TYPE SIZES */
/* ---------------------------------------------------------------- */
/* The size of `int', as computed by sizeof. */
#define SIZEOF_INT 4
/* The size of `short', as computed by sizeof. */
#define SIZEOF_SHORT 2
/* ---------------------------------------------------------------- */
/* STRUCT RELATED */
/* ---------------------------------------------------------------- */
/* Define this if you have struct addrinfo */
#define HAVE_STRUCT_ADDRINFO 1
/* Define this if you have struct sockaddr_storage */
#ifndef __SALFORDC__
#define HAVE_STRUCT_SOCKADDR_STORAGE 1
#endif
/* Define this if you have struct timeval */
#define HAVE_STRUCT_TIMEVAL 1
/* ---------------------------------------------------------------- */
/* COMPILER SPECIFIC */
/* ---------------------------------------------------------------- */
/* Define to avoid VS2005 complaining about portable C functions */
#if defined(_MSC_VER) && (_MSC_VER >= 1400)
#define _CRT_SECURE_NO_DEPRECATE 1
#define _CRT_NONSTDC_NO_DEPRECATE 1
#endif
/* Officially, Microsoft's Windows SDK versions 6.X do not support Windows
2000 as a supported build target. VS2008 default installations provide an
embedded Windows SDK v6.0A along with the claim that Windows 2000 is a
valid build target for VS2008. Popular belief is that binaries built using
Windows SDK versions 6.X and Windows 2000 as a build target are functional */
#if defined(_MSC_VER) && (_MSC_VER >= 1500)
# define VS2008_MINIMUM_TARGET 0x0500
#endif
/* When no build target is specified VS2008 default build target is Windows
Vista, which leaves out even Winsows XP. If no build target has been given
for VS2008 we will target the minimum Officially supported build target,
which happens to be Windows XP. */
#if defined(_MSC_VER) && (_MSC_VER >= 1500)
# define VS2008_DEFAULT_TARGET 0x0501
#endif
/* VS2008 default target settings and minimum build target check */
#if defined(_MSC_VER) && (_MSC_VER >= 1500)
# ifndef _WIN32_WINNT
# define _WIN32_WINNT VS2008_DEFAULT_TARGET
# endif
# ifndef WINVER
# define WINVER VS2008_DEFAULT_TARGET
# endif
# if (_WIN32_WINNT < VS2008_MINIMUM_TARGET) || (WINVER < VS2008_MINIMUM_TARGET)
# error VS2008 does not support Windows build targets prior to Windows 2000
# endif
#endif
/* When no build target is specified Pelles C 5.00 and later default build
target is Windows Vista. We override default target to be Windows 2000. */
#if defined(__POCC__) && (__POCC__ >= 500)
# ifndef _WIN32_WINNT
# define _WIN32_WINNT 0x0500
# endif
# ifndef WINVER
# define WINVER 0x0500
# endif
#endif
/* Availability of freeaddrinfo, getaddrinfo and getnameinfo functions is
quite convoluted, compiler dependent and even build target dependent. */
#if defined(HAVE_WS2TCPIP_H)
# if defined(__POCC__)
# define HAVE_FREEADDRINFO 1
# define HAVE_GETADDRINFO 1
# define HAVE_GETNAMEINFO 1
# elif defined(_WIN32_WINNT) && (_WIN32_WINNT >= 0x0501)
# define HAVE_FREEADDRINFO 1
# define HAVE_GETADDRINFO 1
# define HAVE_GETNAMEINFO 1
# elif defined(_MSC_VER) && (_MSC_VER >= 1200)
# define HAVE_FREEADDRINFO 1
# define HAVE_GETADDRINFO 1
# define HAVE_GETNAMEINFO 1
# endif
#endif
#if defined(__POCC__)
# ifndef _MSC_VER
# error Microsoft extensions /Ze compiler option is required
# endif
# ifndef __POCC__OLDNAMES
# error Compatibility names /Go compiler option is required
# endif
#endif
/* ---------------------------------------------------------------- */
/* IPV6 COMPATIBILITY */
/* ---------------------------------------------------------------- */
/* Define this if you have address family AF_INET6 */
#ifdef HAVE_WINSOCK2_H
#define HAVE_AF_INET6 1
#endif
/* Define this if you have protocol family PF_INET6 */
#ifdef HAVE_WINSOCK2_H
#define HAVE_PF_INET6 1
#endif
/* Define this if you have struct in6_addr */
#ifdef HAVE_WS2TCPIP_H
#define HAVE_STRUCT_IN6_ADDR 1
#endif
/* Define this if you have struct sockaddr_in6 */
#ifdef HAVE_WS2TCPIP_H
#define HAVE_STRUCT_SOCKADDR_IN6 1
#endif
/* Define this if you have sockaddr_in6 with scopeid */
#ifdef HAVE_WS2TCPIP_H
#define HAVE_SOCKADDR_IN6_SIN6_SCOPE_ID 1
#endif
#endif /* __ARES_CONFIG_WIN32_H */

1
deps/c-ares/get_ver.awk

@ -1,7 +1,6 @@
# ***************************************************************************
# * Project: c-ares
# *
# * $Id$
# ***************************************************************************
# awk script which fetches c-ares version number and string from input
# file and writes them to STDOUT. Here you can get an awk version for Win32:

1
deps/c-ares/inet_net_pton.c

@ -1,4 +1,3 @@
/* $Id$ */
/*
* Copyright (c) 2004 by Internet Systems Consortium, Inc. ("ISC")

1
deps/c-ares/inet_net_pton.h

@ -1,7 +1,6 @@
#ifndef __ARES_INET_NET_PTON_H
#define __ARES_INET_NET_PTON_H
/* $Id$ */
/* Copyright (C) 2005 by Daniel Stenberg
*

1
deps/c-ares/inet_ntop.c

@ -1,4 +1,3 @@
/* $Id$ */
/* Copyright (c) 1996 by Internet Software Consortium.
*

1
deps/c-ares/inet_ntop.h

@ -1,7 +1,6 @@
#ifndef __ARES_INET_NTOP_H
#define __ARES_INET_NTOP_H
/* $Id$ */
/* Copyright (C) 2005 by Dominick Meglio
*

1
deps/c-ares/nameser.h

@ -1,4 +1,3 @@
/* $Id$ */
#ifndef ARES_NAMESER_H
#define ARES_NAMESER_H

58
deps/c-ares/setup_once.h

@ -1,9 +1,8 @@
#ifndef __SETUP_ONCE_H
#define __SETUP_ONCE_H
/* $Id$ */
/* Copyright (C) 2004 - 2009 by Daniel Stenberg et al
/* Copyright (C) 2004 - 2010 by Daniel Stenberg et al
*
* Permission to use, copy, modify, and distribute this software and its
* documentation for any purpose and without fee is hereby granted, provided
@ -255,24 +254,42 @@ struct timeval {
/*
* Typedef to 'unsigned char' if bool is not an available 'typedefed' type.
* 'bool' exists on platforms with <stdbool.h>, i.e. C99 platforms.
* On non-C99 platforms there's no bool, so define an enum for that.
* On C99 platforms 'false' and 'true' also exist. Enum uses a
* global namespace though, so use bool_false and bool_true.
*/
#ifndef HAVE_BOOL_T
typedef unsigned char bool;
#define HAVE_BOOL_T
typedef enum {
bool_false = 0,
bool_true = 1
} bool;
/*
* Use a define to let 'true' and 'false' use those enums. There
* are currently no use of true and false in libcurl proper, but
* there are some in the examples. This will cater for any later
* code happening to use true and false.
*/
# define false bool_false
# define true bool_true
# define HAVE_BOOL_T
#endif
/*
* Default definition of uppercase TRUE and FALSE.
* Redefine TRUE and FALSE too, to catch current use. With this
* change, 'bool found = 1' will give a warning on MIPSPro, but
* 'bool found = TRUE' will not. Change tested on IRIX/MIPSPro,
* AIX 5.1/Xlc, Tru64 5.1/cc, w/make test too.
*/
#ifndef TRUE
#define TRUE 1
#define TRUE true
#endif
#ifndef FALSE
#define FALSE 0
#define FALSE false
#endif
@ -367,38 +384,63 @@ typedef int sig_atomic_t;
#define EINTR WSAEINTR
#undef EINVAL /* override definition in errno.h */
#define EINVAL WSAEINVAL
#undef EWOULDBLOCK /* override definition in errno.h */
#define EWOULDBLOCK WSAEWOULDBLOCK
#undef EINPROGRESS /* override definition in errno.h */
#define EINPROGRESS WSAEINPROGRESS
#undef EALREADY /* override definition in errno.h */
#define EALREADY WSAEALREADY
#undef ENOTSOCK /* override definition in errno.h */
#define ENOTSOCK WSAENOTSOCK
#undef EDESTADDRREQ /* override definition in errno.h */
#define EDESTADDRREQ WSAEDESTADDRREQ
#undef EMSGSIZE /* override definition in errno.h */
#define EMSGSIZE WSAEMSGSIZE
#undef EPROTOTYPE /* override definition in errno.h */
#define EPROTOTYPE WSAEPROTOTYPE
#undef ENOPROTOOPT /* override definition in errno.h */
#define ENOPROTOOPT WSAENOPROTOOPT
#undef EPROTONOSUPPORT /* override definition in errno.h */
#define EPROTONOSUPPORT WSAEPROTONOSUPPORT
#define ESOCKTNOSUPPORT WSAESOCKTNOSUPPORT
#undef EOPNOTSUPP /* override definition in errno.h */
#define EOPNOTSUPP WSAEOPNOTSUPP
#define EPFNOSUPPORT WSAEPFNOSUPPORT
#undef EAFNOSUPPORT /* override definition in errno.h */
#define EAFNOSUPPORT WSAEAFNOSUPPORT
#undef EADDRINUSE /* override definition in errno.h */
#define EADDRINUSE WSAEADDRINUSE
#undef EADDRNOTAVAIL /* override definition in errno.h */
#define EADDRNOTAVAIL WSAEADDRNOTAVAIL
#undef ENETDOWN /* override definition in errno.h */
#define ENETDOWN WSAENETDOWN
#undef ENETUNREACH /* override definition in errno.h */
#define ENETUNREACH WSAENETUNREACH
#undef ENETRESET /* override definition in errno.h */
#define ENETRESET WSAENETRESET
#undef ECONNABORTED /* override definition in errno.h */
#define ECONNABORTED WSAECONNABORTED
#undef ECONNRESET /* override definition in errno.h */
#define ECONNRESET WSAECONNRESET
#undef ENOBUFS /* override definition in errno.h */
#define ENOBUFS WSAENOBUFS
#undef EISCONN /* override definition in errno.h */
#define EISCONN WSAEISCONN
#undef ENOTCONN /* override definition in errno.h */
#define ENOTCONN WSAENOTCONN
#define ESHUTDOWN WSAESHUTDOWN
#define ETOOMANYREFS WSAETOOMANYREFS
#undef ETIMEDOUT /* override definition in errno.h */
#define ETIMEDOUT WSAETIMEDOUT
#undef ECONNREFUSED /* override definition in errno.h */
#define ECONNREFUSED WSAECONNREFUSED
#undef ELOOP /* override definition in errno.h */
#define ELOOP WSAELOOP
#ifndef ENAMETOOLONG /* possible previous definition in errno.h */
#define ENAMETOOLONG WSAENAMETOOLONG
#endif
#define EHOSTDOWN WSAEHOSTDOWN
#undef EHOSTUNREACH /* override definition in errno.h */
#define EHOSTUNREACH WSAEHOSTUNREACH
#ifndef ENOTEMPTY /* possible previous definition in errno.h */
#define ENOTEMPTY WSAENOTEMPTY

1
deps/c-ares/windows_port.c

@ -1,6 +1,5 @@
#include "ares_setup.h"
/* $Id$ */
/* only do the following on windows
*/

Loading…
Cancel
Save