Change the upstream source URL
[platform/upstream/c-ares.git] / CHANGES
diff --git a/CHANGES b/CHANGES
index 4d912d6..607545d 100644 (file)
--- a/CHANGES
+++ b/CHANGES
    Changelog for the c-ares project. Generated with git2changes.pl
 
-Version 1.11.0 (19 Feb 2016)
+Version 1.17.1 (19 Nov 2020)
 
-Daniel Stenberg (19 Feb 2016)
-- RELEASE-NOTES: final edits for 1.11.0
+GitHub (19 Nov 2020)
+- [Brad House brought this change]
 
-David Drysdale (15 Feb 2016)
-- ares_dup.3: remove mention of nonexistent function
+  Travis: add iOS target built with CMake (#378)
   
-  ares_dup_options() doesn't exist, so don't document it.
-
-- test: skip repeated build steps
+  Issue #377 suggested that CMake builds for iOS with c-ares were broken. This PR adds an automatic Travis build for iOS CMake.
   
-  Top-level buildconf/configure now triggers for the
-  test/ subdir too, so don't need to do explicitly.
+  Fix By: Brad House (@bradh352)
 
-- test: namespaces unavailable when cross-compiling
+bradh352 (18 Nov 2020)
+- fix build
 
-Daniel Stenberg (13 Feb 2016)
-- configure: only run configure in test when NOT cross-compiling
-  
-  ... as the tests won't run cross-compiled anyway
+GitHub (18 Nov 2020)
+- [Fabrice Fontaine brought this change]
 
-David Drysdale (13 Feb 2016)
-- test: prefer ON_CALL to EXPECT_CALL to reduce flakes
-  
-  For UDP tests, there's a chance of a retry.  EXPECT_CALL only
-  expects a single request to arrive at the server; ON_CALL allows
-  for a UDP retry and repeats the same answer.
+  External projects were using non-public header ares_dns.h, make public again (#376)
   
-  Note that ON_CALL and EXPECT_CALL can't be mixed in the same
-  test, and that tests that have a varied sequence of responses
-  for the same repeated request still have to use EXPECT_CALL.
-
-Daniel Stenberg (13 Feb 2016)
-- configure: run configure in 'test' too
+  It appears some outside projects were relying on macros in ares_dns.h, even though it doesn't appear that header was ever meant to be public.  That said, we don't want to break external integrators so we should distribute this header again.
   
-  Having the test dir completely stand-alone causes too many issues for
-  users and devs. It still needs to be built specifically.
+  Fix By: Fabrice Fontaine (@ffontaine)
 
-- configure: build silently by default
+bradh352 (17 Nov 2020)
+- note that so versioning has moved to configure.ac
 
-- buildconf: run test/buildconf too if present
+- note about 1.17.1
 
-- test/configure: build silently by default
+- fix sed gone wrong
 
-- [Gregor Jasny brought this change]
+GitHub (17 Nov 2020)
+- [Daniel Stenberg brought this change]
 
-  dist: Distribute README.md
+  autotools cleanup (#372)
   
-  Closes #42
+  * remove: install-sh mkinstalldirs
+  
+  They're generated when needed, no need to store in it.
+  
+  * buildconf: remove custom logic with autoreconf
+  
+  Fix By: Daniel Stenberg (@bagder)
 
-Version 1.11.0 (11 Feb 2016)
+bradh352 (17 Nov 2020)
+- attempt to fix 1.17.0 release distribution issues
 
-Daniel Stenberg (11 Feb 2016)
-- Makefile.am: distribute the test dir too
+Version 1.17.0 (16 Nov 2020)
 
-- RELEASE-NOTES: synced with 385582bd14b68a
+bradh352 (16 Nov 2020)
+- 1.17.0 release prep
 
-- [Nicolas \"Pixel\" Noble brought this change]
+- ares_getaddrinfo(): duplicate hints ai_socktype and ai_protocol into output
+  
+  ai_socktype and ai_protocol were ignored from the hints input.  They are now
+  duplicated into the output as expected.  Currently no sanity checks on
+  proper values are taking place.
+  
+  Fixes: #317
+  Fix By: Brad House (@bradh352)
 
-  ares_win32_init: make LoadLibrary work when using UNICODE too
+- ares_parse_{a,aaaa}_reply could return larger *naddrttls than passed in
   
-  Closes #17
+  If there are more ttls returned than the maximum provided by the requestor, then
+  the *naddrttls response would be larger than the actual number of elements in
+  the addrttls array.
+  
+  This bug could lead to invalid memory accesses in applications using c-ares.
+  
+  This behavior appeared to break with PR #257
+  
+  Fixes: #371
+  Reported By: Momtchil Momtchev (@mmomtchev)
+  Fix By: Brad House (@bradh352)
 
-David Drysdale (11 Feb 2016)
-- Use "resolve" as synonym of "dns" in nsswitch.conf
+GitHub (5 Nov 2020)
+- [Dustin Lundquist brought this change]
+
+  docs: ares_set_local_ip4() uses host byte order (#368)
   
-  Modern Linux systems may have libnss_resolve from systemd as the
-  resolver, which is then configured in /etc/nsswitch.conf with
-  the "resolve" keyword rather than "dns".
+  Properly document brain-dead behavior of ares_set_local_ip4() using host byte order instead of expected network byte order.
   
-  Fixes #33
+  Fix By: Dustin Lundquist <d.lundquist@tempered.io>
 
-- ares_set_socket_callback: make manpage match code
+- [Łukasz Marszał brought this change]
+
+  empty hquery->name could lead to invalid memory access (#367)
   
-  The code in ares_process.c that invokes the socket creation/connection
-  callback only checks for rc < 0, not for standard ares error codes.
+  If hquery->name is empty (=="\0"), &hquery->name[strlen(hquery->name)-1] would point to "random" place in memory. This is causing some of my address sanitizer tests to fail.
+  
+  Fix By: Łukasz Marszał (@lmarszal)
 
-- Merge pull request #36 from AGWA-forks/master
+bradh352 (28 Sep 2020)
+- Fix OSSFuzz reported issue in CAA reply parsing
   
-  Add ares_set_socket_configure_callback()
+  OSS-Fuzz is reporting a use-of-uninitialized-value:
+  https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=26012
+  
+  Reported By: David Drysdale (@daviddrysdale)
 
-- test: Update init tests to match behaviour
+GitHub (26 Sep 2020)
+- [David Hotham brought this change]
+
+  fuzz CAA parsing (#363)
   
-  Unreadable config files are now treated the same way
-  as absent config files.
+  Add fuzz support for CAA parsing
+  
+  Fix By: David Hotham (@dimbleby)
 
-- [Fedor Indutny brought this change]
+- [Daniela Sonnenschein brought this change]
 
-  Ignore `fopen` errors to use default values
+  Allow parsing of CAA Resource Record (#360)
   
-  After 46bb820be3a83520e70e6c5f0c5133253fcd69cd `init_by_resolv_conf`
-  errors are no longer swallowed in `ares_init_options`. This has exposed
-  a previously unknown bug in `lookups` initialization code.
+  CAA (Certification Authority Authorization) was introduced in RFC 6844.
+  This has been obsoleted by RFC 8659. This commit added the possibility
+  to query CAA resource records with adig and adds a parser for CAA
+  records, that can be used in conjunction with ares_query(3).
   
-  If there is no lookup configuration in `resolv.conf`,
-  `init_by_resolv_conf` will attempt to read it from other files available
-  on the system. However, some of these files may have restricted
-  permissions (like `600`), which will lead to `EACCESS` errno, which in
-  turn is handled like a fatal error by `init_by_resolv_conf`.
+  Closes Bug: #292
+  Fix By: Daniela Sonnenschein (@lxdicted)
+
+Daniel Stenberg (17 Sep 2020)
+- docs: remove the html and pdf make targets
   
-  However, it sounds illogical that this error should be handled as a
-  fatal. There is a `init_by_defaults` call that overrides `lookups` with
-  default value, and certainly possible absence of lookup information is
-  the reason why this function exists in a first place!
+  They're rarely used in our daily work flow and mostly just add friction,
   
-  I suggest handling any `fopen` errors as non-fatal ones, allowing to
-  pick up the `lookups` value from different config files, or to pick up
-  default value.
+  Closes #362
 
-Andrew Ayer (9 Feb 2016)
-- Document callback type in man page for ares_set_socket_callback
+bradh352 (14 Sep 2020)
+- ares_process needs to always include nameser.h as it has compat
 
-- Add ares_set_socket_configure_callback()
+- Define T_OPT if system doesn't provide it
+
+GitHub (12 Sep 2020)
+- [Gisle Vanem brought this change]
+
+  Change the mailman links (#358)
   
-  This function sets a callback that is invoked after the socket is
-  created, but before the connection is established.  This is an ideal
-  time to customize various socket options.
+  Links when wrapping become misleading.  Insert newline to prevent wrapping.
+  
+  Fix By: Gisle Vanem (@gvanem)
 
-David Drysdale (9 Feb 2016)
-- test: ares_set_socket_callback failure behaviour
+- [Gisle Vanem brought this change]
 
-- test: Check ares_parse_txt_reply_ext() entrypoint
+  [adig] Update man-page for the '-x' option (#357)
+  
+  Fix By: Gisle Vanem (@gvanem)
 
-- [Fedor Indutny brought this change]
+- [Gisle Vanem brought this change]
 
-  txt: introduce `ares_parse_txt_reply_ext`
+  [adig] add '-x' option. (#356)
   
-  Introduce `ares_txt_ext` structure with an extra `record_start`
-  field, which indicates a start of a new TXT record, thus allowing to
-  differentiate the chunks in the same record, from a chunks in a
-  different record.
+  Added a 'dig-style' '-x' option. Also support '-xx' for a
+  IPv6 bit-string PTR query.
   
-  Introduce a new API method: `ares_parse_txt_reply_ext` that works with
-  this kind of struct.
+  Fix By: Gisle Vanem (@gvanem)
 
-- doc: Update missed repo references
+bradh352 (12 Sep 2020)
+- fix indentation
 
-- doc: Update docs on contributing
+- ns_t_opt -> T_OPT
 
-- test: Run command line tools in Travis
+GitHub (12 Sep 2020)
+- [Gisle Vanem brought this change]
+
+  Fixes for Watt-32 on djgpp + Windows (#355)
   
-  Do a quick execution of each of the command line tools
-  in the continuous integration build, so that any (say)
-  sanitizer failures show up.
+  No longer any relation to libcurl since '<libcurl-root>/packages/DOS/common.dj' is dropped.
+  This Makefile.dj has been tested on Win-10 only (using the Windows hosted djgpp cross compiler).
+  
+  Fix By: Gisle Vanem (@gvanem)
 
-- acountry: drop inert test
+- [Gisle Vanem brought this change]
+
+  Fixes for Watt-32 on Windows and MSDOS (#354)
   
-  If ver_1 is true, then z0 and z1 must both be 'z', and so
-  (z0 != 'z' && z1 != 'z') can never be true.
+  Move the prototype to 'ares_private.h'.
   
-  CID 56879, pointed out by Coverity.
+  Fix By: Gisle Vanem (@gvanem)
 
-- doc: update badge locations to master repo
+bradh352 (11 Sep 2020)
+- update path for include
 
-- test: Enable maintainer mode + debug in Travis
+- remove stale information
 
-- test: Add an iOS build target
+- remove stale information
 
-- test: Ignore SIGPIPE in tests
+Brad House (9 Sep 2020)
+- silence compiler warnings
 
-- test: More initialization tests
+- Remove stale msvc files from makefile
 
-- test: Improve containerized test mechanism
+GitHub (9 Sep 2020)
+- [Brad House brought this change]
+
+  Reorganize source tree (#349)
   
-  Aim is to ensure that code coverage information can escape the
-  container.  To do this:
-   - Enter a new mount namespace too, so that we can...
-   - Bind mount the expected source directory into the container
-   - Share memory with the sub-process so coverage information is
-     shared too.
+  Originally started by Daniel Stenberg (@bagder) with #123, this patch reorganizes the c-ares source tree to have a more modern layout.  It also fixes out of tree builds for autotools, and automatically builds the tests if tests are enabled.  All tests are passing which tests each of the supported build systems (autotools, cmake, nmake, mingw gmake).  There may be some edge cases that will have to be caught later on for things I'm not aware of.
+  
+  Fix By: Brad House (@bradh352)
 
-- test: Make contained tests easier to write
+Brad House (1 Sep 2020)
+- remove CURLDEBUG as per #82
 
-- test: Add framework for containerized testing
+GitHub (1 Sep 2020)
+- [Erik Lax brought this change]
+
+  Detect remote DNS server does not support EDNS as per RFC 6891 (#244)
   
-  On Linux we can potentially use user and UTS namespaces to run  a test
-  in a pseudo-container with:
-   - arbitrary filesystem (e.g. /etc/resolv.conf, /etc/nsswitch.conf, /etc/hosts)
-   - arbitrary hostname/domainname.
+  EDNS retry should be based on FORMERR returned without an OPT RR record as per https://tools.ietf.org/html/rfc6891#section-7 rather than just treating any unexpected error condition as a reason to disable EDNS on the channel.
   
-  Include a first pass at the framework code to allow this, along with a
-  first test case that uses the container.
+  Fix By: Erik Lax (@eriklax)
 
-- test: Use a longer timeout for less flakiness
+Brad House (27 Aug 2020)
+- Fix for #345, don't use 'true' use 1
+
+GitHub (27 Aug 2020)
+- [Seraphime Kirkovski brought this change]
+
+  ares_gethostbyname: Fix AF_UNSPEC support when using an ip address (#204)
   
-  Having occasional test failures from timeout before multiple
-  queries can complete, so up the default timeout for the test
-  from 100ms to 1500ms.
+  fake_hostent() was not supporting AF_UNSPEC, so when an ip address was specified when using AF_UNSPEC it would attempt to do a DNS lookup rather than returning a fake hostent using the ip address.
+  
+  Fix By: Seraphime Kirkovski (@Seraphime)
 
-- test: Make failure tests more robust
+- [apenn-msft brought this change]
+
+  Tests should use dynamic system-assigned ports rather than static port (#346)
   
-  Different platforms will do different numbers of allocations
-  in the processing of a given API call; just check that the
-  return code is either success or ENOMEM, and free off any
-  returned state in the former case.
+  The c-ares test suite was hardcoded to use port 5300 (and possibly 5301, 5302) for the test suite.  Especially in containers, there may be no guarantee these ports are available and cause tests to fail when they could otherwise succeed.  Instead, request the system to assign a port to use dynamically.  This is now the default.  To override, the test suite still takes the "-p <port>" option as it always has and will honor that.
   
-  Also cope with ECONNREFUSED as well as ENOTFOUND.
+  Fix By: Anthony Penniston (@apenn-msft)
 
-- test: Get test code building under Windows
+Brad House (25 Aug 2020)
+- Unset members of the addr struct contain garbage values (#343)
   
-   - Initial nmake file based off library nmake file
-   - Cast socket call arguments to (char *)
-   - Use wrapper sclose() that maps to closesocket() or close()
-   - Build a config.h indicating presence of headers
-   - Conditionally include netdb.h
-   - Remove unnecessary include of sys/socket.h
-   - Force longer bitmask for allocation failure tracking
-   - Call WSAStartup() / WSACleanup() in main()
-   - Set TCP_NODELAY for mock server
-   - Turn on tests in AppVeyor build
+  When generating the ares_sockaddr data by getaddrinfo() it was only filling
+  in certain members while leaving others uninitialized.  This left garbage
+  data if a user tried to use the unset values.  memset() the ares_sockaddr
+  to 0 prior to filling in the values to prevent this.
+  
+  Reported By: @SmorkalovG
+  Fix By: Brad House (@bradh352)
 
-- test: Disable tests that manipulate env on Windows
+GitHub (24 Aug 2020)
+- [Jonathan Maye-Hobbs brought this change]
 
-- test: Move file lists into Makefile.inc
+  FQDN with trailing period should be queried first with larger ndot value (#345)
   
-  In preparation for a Win32 build of the test suite.
-
-- test: Add a simple multi-server test
+  If a query is performed for dynamodb.us-east-1.amazonaws.com. with ndots=5, it was attempting to search the search domains rather than just attempting the FQDN that was passed it.  This patch now at least attempts the FQDN first.
   
-  Check rotate option does something
-
-- test: Allow for multiple mock servers
+  We may need to determine if we should abort any further searching, however as is probably intended.
   
-   - Update the MockServer to allow separate specification of
-     UDP and TCP ports
-   - Have an array of mock servers listening on consecutive
-     sets of ports.
-   - Rename Process(fd) to ProcessFD(fd) to avoid confusion.
-   - Initialize channel by using the new ares_set_servers_ports()
-     entrypoint, so multiple ports on the same loopback address
-     can be used.
+  Fix by: Jonathan Maye-Hobbs (@wheelpharoah)
 
-- test: Update test for set/get_servers variants
-  
-  Ports are significant in the _ports_ variant functions, so update test to cope.
+- [Gisle Vanem brought this change]
 
-- test: Make GetNameServers() utility function port-aware
+  Update acountry.c country code list (#341)
   
-  Also make it generally available.
+  Updated country_list[]:
+   * 2-letter ISO-3166 country-codes.
+   * Add, rename some names + codes in accordance with latest table at https://en.wikipedia.org/wiki/ISO_3166-1.
+  
+  Fix By: Gisle Vanem (@gvanem)
 
-- test: more testing, including of internal static functions
+- [Bulat Gaifullin brought this change]
 
-- test: more tests, especially fallback processing
+  Test case should honor flag HAVE_WRITEV rather than WIN32 (#344)
   
-   - Make mock server listen on UDP + TCP in parallel.
-   - Test UDP->TCP fallback on truncation
-   - Test EDNS->no-EDNS fallback
-   - Test some environment init options
-   - Test nonsense reply
+  Test cases where not honoring the HAVE_WRITEV flag but instead using WIN32 to determine if WRITEV was available or not.  This patch fixes that.
   
-  test: short response
+  Fix By: Bulat Gaifullin (@bgaifullin)
 
-- test: more tests, particularly of initialization
+Brad House (18 Jul 2020)
+- Ensure c89 support
+  
+  A couple of for loops in Mac-specific code were using integer declarations
+  inside a for loop.  Move the declaration to the top of the preceding
+  code block to retain c89 compliance.
+  
+  Reported By: Jeffrey Walton
 
-- test: Run mock tests over both TCP and UDP
+GitHub (2 Jul 2020)
+- [Fionn Fitzmaurice brought this change]
+
+  Avoid buffer overflow in RC4 loop comparison (#336)
   
-  With the exception of a few tests that make use of the timed
-  retry aspect of UDP.
+  The rc4 function iterates over a buffer of size buffer_len who's maximum
+  value is INT_MAX with a counter of type short that is not guaranteed to
+  have maximum size INT_MAX.
+  
+  In circumstances where short is narrower than int and where buffer_len
+  is larger than the maximum value of a short, it may be possible to loop
+  infinitely as counter will overflow and never be greater than or equal
+  to buffer_len.
+  
+  The solution is to make the comparison be between types of equal width.
+  This commit defines counter as an int.
+  
+  Fix By: Fionn Fitzmaurice (@fionn)
 
-- test: Run mock tests over both IPv4 and IPv6
+- [anonymoushelpishere brought this change]
 
-- test: Add more tests for edge cases
+  Updated help information for adig, acountry, and ahost. (#334)
+  
+  Provide more descriptive help information for various utilities.
+  
+  Fix By: @anonymoushelpishere
 
-- test: more nooks and crannies of pton functions
+- [lutianxiong brought this change]
 
-- test: More tests for PTR parsing
+  avoid read-heap-buffer-overflow (#332)
+  
+  Fix invalid read in ares_parse_soa_reply.c found during fuzzing
+  
+  Fixes Bug: #333
+  Fix By: lutianxiong (@ltx2018)
 
-- test: Use of HOSTALIAS environment variable
+- [Ivan Baidakou brought this change]
 
-- test: Add RAII utility classes for testing
+  Fix: sizeof(sizeof(addr.saX)) -> sizeof(addr.saX) in readaddrinfo (#331)
   
-   - TempFile holds specific contents
-   - EnvValue sets an environment variable
+  Looks like a sed-gone-wrong, a sizeof inside of a sizeof.
+  
+  Fix By: Ivan Baidakou (@basiliscos)
 
-- test: More search domain scenarios
+Version 1.16.1 (11 May 2020)
 
-- test: Remove duplicate flags from Makefile.am
+Brad House (11 May 2020)
+- c-ares 1.16.1 release prep
 
-- test: Make test code leak-free
+- update travis to use xcode11.4
 
-- test: More tests
+- Prevent possible double-free in ares_getaddrinfo() if ares_destroy() is called
   
-   - test use of sortlist
-   - test gethostbyname(AF_UNSPEC)
+  In the event that ares_destroy() is called prior to ares_getaddrinfo() completing,
+  it would result in an invalid read and double-free due to calling end_hquery() twice.
+  
+  Reported By: Jann Horn @ Google Project Zero
 
-- test: Test ares_gethostbyname_file()
+GitHub (30 Apr 2020)
+- [shelley vohr brought this change]
 
-- test: Add more tests of ares_getnameinfo()
+  fix: windows UNICODE incompatibilities with ares_getaddrinfo (#328)
+  
+  Fixes the following compatibility issues:
+  * Use RegQueryValueExA instead of RegQueryValueEx
+  * Use ExpandEnvironmentStringsA instead of ExpandEnvironmentStrings
+  * Use RegOpenKeyExA instead of RegOpenKeyExA
+  * Use GetWindowsDirectoryA instead of GetWindowsDirectoryA
+  
+  Fix By: Shelley Vohr (@codebytere)
+  Closes: #327
 
-- test: Tweak tests, add alloc failure test
+Brad House (13 Apr 2020)
+- travis: CloudFlare does not allow T_ANY requests, so live tests that use it fail.  Disable.
 
-- test: Test init with options
+- travis: bump macos image to the latest
 
-- test: More tests
+- cast-align warnings are false for struct sockaddr, silence
   
-   - ares_inet_net_pton() variants
-   - ares_getsock() variants
+  Create a macro to silence false cast-align warnings when casting
+  struct sockaddr * to struct sockaddr_in * and struct sockaddr_in6 *.
+  
+  Fix By: Brad House (@bradh352)
 
-- test: Expose ProcessWork() function
+- MacOS: Enable libresolv support for retrieving DNS servers like iOS does.
 
-- test: More parsing tests
+GitHub (10 Apr 2020)
+- [Dmitry Igrishin brought this change]
+
+  CMake: Populate the INCLUDE_DIRECTORIES property of installed targets (#323)
   
-  Including:
-   - Split each parse function test set out into separate files.
-   - Add an allocation failure test for each parsing function.
-   - Add error check test for each parsing function.
+  Populate the INCLUDE_DIRECTORIES property of installed targets
+  
+  Fix By: Dmitry Igrishin (@dmitigr)
 
-- test: Add various additional tests
+Brad House (10 Apr 2020)
+- travis: make valgrind use cmake for tests
 
-- test: More tests
-  
-  Include tests of internal functions, based on the value of the
-  CARES_SYMBOL_HIDING macro; need to configure the library with
-  --disable-symbol-hiding to enable these tests.
+- dont try to use libtool to run valgrind
 
-- test: Allow command line override of mock server port
+- valgrind requires libtool installed to wrap tests
 
-- test: Add README.md documentation
+- scan build 7
 
-- test: Temporarily avoid latest Python requests package
+- fix travis live test
+
+- add debug for travis
+
+- try without sudo
+
+- attempt to modernize travis build environment
+
+GitHub (6 Apr 2020)
+- [Teemu R brought this change]
+
+  Allow TXT records on CHAOS qclass (#321)
   
-  Currently get error from Travis on this install step, and downgrading one
-  version appears to fix the problem.
+  Some DNS servers intentionally "misuse" the obsoleted CHAOS (CH) qclass to provide things like `version.bind`, `version.server`, `authors.bind`, `hostname.bind` and `id.server`.
   
-  "Could not find any downloads that satisfy the requirement pyOpenSSL>=0.13
-  (from requests[security])"
+  C-ares was not allowing such use cases.
+  
+  Fix By: Teemu R. (@rytilahti)
 
-- test: Add AppVeyor config file for Windows build
+Brad House (5 Apr 2020)
+- Remove warnings from ares_getaddrinfo.3 man page
+  
+  As reported in #319, non-standard macros of .IN were used.
+  Replace with .RS/.RE.
+  
+  Fixes: #319
+  Fix By: Brad House (@bradh352)
 
-- test: Add configuration for a Travis build
+- ares_getaddrinfo man page render better for man2html
+
+- update man pages to render better for man2html
+
+Version 1.16.0 (12 Mar 2020)
+
+Brad House (12 Mar 2020)
+- 1.16.0 release notes draft
+
+- attempt to fix double-free introduced in e0517f9
+
+GitHub (12 Mar 2020)
+- [David Drysdale brought this change]
+
+  test: fuzzer input triggering double free (#315)
   
-  Cover Linux & OSX on the container infrastructure, but install
-  a later G++ to satisfy the tests' need for C++11.
+  OSS-Fuzz has reported a double-free with the fuzzer input file
+  included here; run with:
+    ./test/aresfuzz test/fuzzinput/clusterfuzz-5637790584012800
   
-  Use a build matrix to include a variety of build variants:
-   - ASAN
-   - UBSAN
-   - LSAN
-   - Coverage via coveralls.io
+  Bisecting the failure points to commit e0517f97d988 ("Parse SOA records
+  from ns_t_any response (#103)")
+
+- [Brad House brought this change]
+
+  CMake: Install Manpages (#314)
   
-  test: invoke ASAN and coverage in Travis build
+  CMake wasn't installing manpages.
   
-  Also shift to use explicit build matrix
+  Fixes #297
+  Fix By: Brad House (@bradh352)
+
+- [Brad House brought this change]
+
+  Enable cmake tests for AppVeyor (#313)
   
-  test: Use coveralls.io for coverage tracking
+  Tests require linking against the static library on Windows otherwise the symbols are not exported for internals being tested.
   
-  test: Add a build with UBSAN
+  Fix By: Brad House (@bradh352)
+
+Brad House (11 Mar 2020)
+- Add AppVeyor badge
+
+- bump c-ares version to 1.16.0. test AppVeyor integration.
+
+GitHub (11 Mar 2020)
+- [Brad House brought this change]
+
+  replace all usages of inet_addr() with ares_inet_pton() which is more proper (#312)
   
-  Also expand and re-order the setting of environment variables
-  for easier modification.
+  Replace usage of inet_addr() with ares_inet_pton() which is more appropriate and fixes issues with legitimate addresses like 255.255.255.0. IPv6 already used this.
   
-  test: Add LSAN build to Travis config
+  Fixes #309
+  Fix By: Brad House (@bradh352)
 
-- test: Add initial unit tests for c-ares library
+- [Brad House brought this change]
+
+  CMake: Generate WinPDB files during build (#311)
   
-  The tests are written in C++11, using the GoogleTest and GoogleMock
-  frameworks.  They have their own independent autoconf setup, so that
-  users of the library need not have a C++ compiler just to get c-ares
-  working (however, the test/configure.ac file does assume the use of
-  a shared top-level m4/ directory).  However, this autoconf setup has
-  only been tested on Linux and OSX so far.
+  Build and Install PDB (Windows Debug Symbol) files if supported by underlying system.
   
-  Run with "./arestest", or "./arestest -v" to see extra debug info.
-  The GoogleTest options for running specific tests are also
-  available (e.g. "./arestest --gtest_filter=*Live*").
+  Also update AppVeyor to test cmake builds.
   
-  The tests are nowhere near complete yet (currently hitting around
-  60% coverage as reported by gcov), but they do include examples
-  of a few different styles of testing:
+  Fixes #245
+  Fix By: Piotr Pietraszkiewicz (@ppietrasa) and Brad House (@bradh352)
+
+- [Brad House brought this change]
+
+  CMake: Rework library function checking (#310)
   
-   - There are live tests (ares-test-live.cc), which assume that the
-     current machine has a valid DNS setup and connection to the
-     internet; these tests issue queries for real domains but don't
-     particularly check what gets returned.  The tests will fail on
-     an offline machine.
+  CHECK_LIBRARY_EXISTS(), while it takes a function name, does not actually verify the function exists in the library being evaluated. Instead, if the function is found in any dependent library, and the referenced library also exists, it returns true. This is not desirable.
   
-   - There a few mock tests (ares-test-mock.cc) that set up a fake DNS
-     server and inject its port into the c-ares library configuration.
-     These tests allow specific response messages to be crafted and
-     injected, and so are likely to be used for many more tests in
-     future.
+  Wrap with a Macro to change the behavior.
   
-      - To make this generation/injection easier, the dns-proto.h file
-        includes C++ helper classes for building DNS packets.
+  Fixes: #307
+  Fix By: Brad House (@bradh352)
+
+- [Dron Rathore brought this change]
+
+  Parse SOA records from ns_t_any response (#103)
   
-   - Other library entrypoints that don't require network activity
-     (e.g. ares_parse_*_reply) are tested directly.
+  Added the capability of parsing SOA record from a response buffer of ns_t_any type query, this implementation doesn't interfere with existing T_SOA query's response as that too is treated as a list of records. The function returns ARES_EBADRESP if no SOA record is found(as per RFC).
   
-   - There are few tests of library-internal functions that are not
-     normally visible to API users (in ares-test-internal.cc).
+  The basic idea of sticking to RFC that a ns_t_any too should return an SOA record is something open for discussion but I have kept the functionality intact as it was previously i.e the function returns ARES_EBADRESP if it doesn't find a SOA record regardless of which response it is parsing i.e. T_SOA or T_ANY.
   
-   - A couple of the tests use a helper method of the test fixture to
-     inject memory allocation failures, using the earlier change to the
-     library to allow override of malloc/realloc/free.
+  Note that asking for T_ANY is generally a bad idea:
+  - https://blog.cloudflare.com/what-happened-next-the-deprecation-of-any/
+  - https://tools.ietf.org/html/draft-ietf-dnsop-refuse-any
   
-   - There is also an entrypoint to allow Clang's libfuzzer to drive
-     the packet parsing code in ares_parse_*_reply, together with a
-     standalone wrapper for it (./aresfuzz) to allow use of afl-fuzz
-     for further fuzz testing.
+  Bug: #102
+  Fix By: Dron Rathore (@DronRathore)
 
-- test: Add local copy of GoogleMock/GoogleTest 1.7.0
-  
-  Don't check in gtest/m4 files, as they are unused and interfere
-  with the top-level configure process.
+- [Stephen Bryant brought this change]
 
-- doc: Show build badges in README.md
+  Added CPack functionality for generating RPM or DEB packages (#283)
   
-  Note that these URLs will need to be updated if/when the test branch
-  gets pulled into the master repo/branch.
-
-- doc: Convert README to README.md
+  Added CPack functionality for generating RPM or DEB packages
   
-  Gives better display on GitHub
-
-- doc: Update in preparation for next release
+  ie: run `cpack -G RPM` (or "DEB") after building with CMake.
   
-  Assume 1.11.0 is next (as there are various API additions).
-  Also add myself to AUTHORS.
+  The current configuration creates 3 separate packages for the shared library,
+  the development files and the tools.
+  
+  Fix By: Stephen Bryant (@bf-bryants)
 
-- build: Allow header compilation by Windows C++ compiler
+- [tjwalton brought this change]
 
-- build: Expose whether symbol hiding is on
+  ares_gethostbyname: Return ENODATA if no valid A or AAAA record found (#304)
   
-  Adding the CARES_SYMBOL_HIDING definition allows the test suite to
-  detect whether internal symbols are available or not.
-
-- build: Add autoconf macros for C++11 code using pthreads
+  ares_gethostbyname() was returning ESUCCESS when no A or AAAA record was found but a CNAME pointing nowhere was present.  ENODATA should be returned instead, however the hosts pointer will still be present to provide the alias list.
   
-  Pull in testing macros from the GNU autoconf archive to allow
-  configure scripts to test for and setup use of a C++11 compiler
-  (AX_CXX_COMPILE_STDCXX_11) and the pthreads library (AX_PTHREAD).
+  * Return ENODATA if no valid A or AAAA record found
+  * Fix and update test ParseAReplyNoData.
+  * Add test for new ENODATA behaviour in ares_gethostbyname.
   
-  Note that these macros are not used by the main library autoconf,
-  just by the tests (which share the same m4/ directory).
+  Fixes Bug #303
+  Fix By: @tjwalton
 
-- build: Add a code coverage option
+- [Michal Rostecki brought this change]
+
+  test: Separate live tests from SetServers* tests (#299)
   
-  Configure with:
-    ./configure --enable-code-coverage
-  Show coverage output with:
-    make code-coverage-capture
+  Before this change, SetServers, SetServersPorts and SetServersCSV
+  contained test cases trying to make DNS queries with the google.com
+  hostname, which requires Internet connectivity. Tests with that
+  requirement should be defined in the ares-test-live.cc file and contain
+  "Live" prefix to filter them out with `--gtest_filter=-*.Live*` on
+  machines without Internet connectivity.
   
-  Built on m4/ax_code_coverage.m4 from the GNU autoconf archive
-  to provide the macros to check for presence of gcov + lcov;
-  upstream macro modified to:
-   - Remove use of $(AM_DEFAULT_VERBOSITY) , as earlier versions of
-     autoconf (such as the one used by default on Travis) do not have this.
-   - Rather than automatically defining CODE_COVERAGE_RULES to be a set
-     of makefile rules that use ifeq/endif (which is GNU make-specific),
-     instead only define CODE_COVERAGE_RULES if coverages is turned on,
-     and in that case don't use conditionals in the makefile.
+  Fix By: Michal Rostecki (@mrostecki)
 
-- api: Add entrypoints to allow use of per-server ports
+- [Adam Majer brought this change]
+
+  Only count valid addresses when response parsing (#302)
   
-  Add user-visible entrypoints ares_{get,set}_servers_ports(3), which
-  take struct ares_addr_port_node rather than struct ares_addr_node.
-  This structure includes a UDP and TCP port number; if this is set
-  to zero, the channel-wide port values are used as before.
+  When ares_parse_a_reply or ares_parse_aaaa_reply is called in case
+  where another AAAA and A responses exist, the resulting ares_addrttl
+  count is invalid and the structure points to gibberish.
   
-  Similarly, add a new ares_set_servers_ports_csv(3) entrypoint, which
-  is analogous to ares_set_servers(3) except it doesn't ignore any
-  specified port information; instead, any per-server specified port
-  is used as both the UDP and TCP port for that server.
+  This is a regression since 1.15.
   
-  The internal struct ares_addr is extended to hold the UDP/TCP ports,
-  stored in network order, with the convention that a value of zero
-  indicates that the channel-wide UDP/TCP port should be used.
+  Issue: https://github.com/c-ares/c-ares/issues/300
+  Fix By: Adam Majer (@AdamMajer)
+
+Brad House (24 Dec 2019)
+- [Kyle Edwards brought this change]
+
+  CMake: Provide c-ares version in package export file (#296)
   
-  For the internal implementation of ares_dup(3), shift to use the
-  _ports() version of the get/set functions, so port information is
-  transferred correctly to the new channel.
+  The CMake package export file should provide version information.
   
-  Update manpages, and add missing ares_set_servers_csv to the lists
-  while we're at it
+  Fix By: Kyle Edwards (@KyleFromKitware)
 
-- api: Add ares_set_sortlist(3) entrypoint
+- [Ben Noordhuis brought this change]
+
+  Accept invalid /etc/resolv.conf lookup values, ability to build container tests (#274)
   
-  Allow explicit configuration of the channel's sortlist, by
-  specifying a string in the same format as the equivalent
-  /etc/resolv.conf option.
+  * Add CARES_BUILD_CONTAINER_TESTS CMake option to add ability to build the Linux-only containerized tests.
+  * Accept invalid /etc/resolv.conf lookup values
   
-  This allows library users to perform the same configuration
-  that is available via /etc/resolv.conf, but without needing
-  to change that file.
+  Before this commit invalid `lookup` values resulted in c-ares not using
+  any lookups without any clear indication why. After this commit it uses
+  the default "fb".
+  
+  Fix By: Ben Noordhuis (@bnoordhuis)
 
-- api: Allow injection of user-specified malloc/free functions
+- [Christian Ammer brought this change]
+
+  Parallel A and AAAA lookups in `ares_getaddrinfo` (#290)
   
-  Add a new ares_library_init_mem() initialization function for the
-  library which allows the library user to specify their own malloc,
-  realloc & free equivalents for use library-wide.
+  A and AAAA lookups for ares_getaddrinfo() are now performed in parallel.
   
-  Store these function pointers in library-wide global variables,
-  defaulting to libc's malloc(), realloc() and free().
+  For this change `ares_search` was removed from `ares_getaddrinfo`.
+  Instead `ares_query` in combination with `next_dns_lookup` are
+  doing the suffix search.
   
-  Change all calls to malloc, realloc and free to use the function pointer
-  instead.  Also ensure that ares_strdup() is always available
-  (even if the local environment includes strdup(3)), and change the
-  library code to always use it.
+  Adding support for `.onion` addresses which are tested by
+  `TEST_F(DefaultChannelTest, GetAddrinfoOnionDomain)`
   
-  Convert calls to calloc() to use ares_malloc() + memset
+  Fix By: Christian Ammer (@ChristianAmmer)
 
-- api: Add option to expose some internal functions
+- [Vy Nguyen brought this change]
+
+  Move variables into the block where it is used to avoid unused-vars (#281)
   
-  Purely for testing, add --enable-expose-statics option to configure
-  which converts some static internal functions to be externally visible.
+  Warning uncovered with [-Werror, -Wunused-variables]
+  
+  Fix By: Vy Nguyen (@oontvoo)
 
-- api: Expose the ares_library_initialized() function
+- [Vy Nguyen brought this change]
 
-- ahost: Allow repeated -s <domain> options
+  Rename local macros to avoid conflicting with system ones and remove unsed variables. (Otherwise code will break once compiled with [-Werror,-Wmacro-redefined,-Wunused-variable] ) (#280)
   
-  This also removes a potential leak where later -s options would
-  replace earlier ones without freeing the relevant string.
-
-- Mark unhittable lines
+  Fix new getaddrinfo code to not redefine macros on some systems.
   
-  Add comments for the benefit of the lcov tool, marking
-  lines that cannot be hit.  Typically these are fall-back
-  protection arms that are already covered by earlier checks,
-  and so it's not worth taking out the unhittable code (in case
-  someone changes the code between the two places in future).
-
-- ares_set_servers_csv.3: make return type match code
+  Fix By: Vy Nguyen (@oontvoo)
 
-- bitncmp: update comment to match code behaviour
+- [Egor Pugin brought this change]
 
-- ares_striendstr: fix so non-NULL return can happen
+  [ares_getenv] Return NULL in all cases. (#279)
   
-  This looks to have been broken since it was first introduced in 2005 in
-  commit aba0b775ea30 ("Added ares_getnameinfo which mimics the
-  getnameinfo API")
-
-- config_sortlist: free any existing sortlist on (re)alloc failure
+  if ares_getenv is defined, it must return a value on all platforms.
   
-  If we get an allocation failure on 2nd or later entry in the sortlist, the
-  code would return ENOMEM but still leave the initial entries allocated.
-  Ensure that *sortlist is set to NULL whenever ENOMEM is returned.
+  Fix By: Egor Pugin (@egorpugin)
 
-- ares_dup: clear new channel on failure
-  
-  If the attempt to transfer IPv6 servers from the old to the new channel
-  fails, the previous code would still return a channel to the user even though
-  an error return code was generated.  This makes it likely that users would
-  leak the channel, so explicitly clear the channel in this case.
+- [Abhishek Arya brought this change]
 
-- ares_init_options: don't lose init failure
+  Add OSS-Fuzz fuzzing badge (#278)
   
-  If (say) init_by_options() fails, the subsequent call to
-  init_by_defaults() was overwriting the return code with
-  success.  Still call init_by_defaults() regardless, but track
-  its return value separately
-
-- ares_gethostbyname: don't leak valid-but-empty hostent
+  Adds based on instructions at
+  https://google.github.io/oss-fuzz/getting-started/new-project-guide/#status-badge
   
-  If an AF_UNSPEC query gets a valid response to its AAAA query,
-  but which has no IPv6 addresses in it, then the code chains on to
-  a A record query.  However, the hostent from the AAAA response
-  was being leaked along the way (because it gets replaced before
-  the follow-on end_hquery() invocation).
+  Patch By: Abhishek Arya (@inferno-chromium)
 
-- ares_parse_txt_reply: propagate errors from per-substring loop
+- [Peter Eisentraut brought this change]
+
+  ares_init_options.3: Fix layout (#275)
   
-  If we get an allocation failure when processing a particular substring in a
-  TXT record, that failure is silently lost; fix that by propagating errors from
-  the inner loop to the outer loop.
+  7e6af8e inserted the documentation of resolvconf_path in the middle of
+  the item for ednspsz, leading to broken layout.  Fix that.
+  
+  Fix By: Peter Eisentraut (@petere)
 
-- process_answer: fix things up correctly when removing EDNS option
+- [Gregor Jasny brought this change]
+
+  manpages: Fix typos detected by lintian (#269)
   
-  When a server rejects an EDNS-equipped request, we retry without
-  the EDNS option.  However, in TCP mode, the 2-byte length prefix was
-  being calculated wrong -- it was built from the answer length rather than
-  the length of the original request.
   
-  Also, it is theoretically possible that the call to realloc() might change
-  the data pointed to; to allow for this, qbuf also needs updating.
+  Fix By: Gregor Jasny (@gjasny)
+
+- [lifenjoiner brought this change]
+
+  keep command line usage up to date (#256)
   
-  (Both these fixes were actually included in a patchset sent on the mailing
-  list in Oct 2012, but were included with other functional changes that
-  didn't get merged:
-  http://c-ares.haxx.se/mail/c-ares-archive-2012-10/0004.shtml)
+  adig and ahost built-in help did not match args taken.
+  
+  Fix-By: @lifenjoiner
 
-- ares__read_line: clear buf pointer on realloc failure
+- [Dan Noé brought this change]
 
-- ares_expand_name: check for valid bits in label length
+  ares-test.cc: Handle nullptr in AddrInfo ostream. (#268)
   
-  The top two bits of the label length indicate whether this is a
-  label length (00) or an index to a name elsewhere in the message
-  (11).  RFC1035 4.1.4 says that the other possible values for the
-  top two bits (01, 10) are reserved for future use.
+  The const AddrInfo& argument to operator<< overload for AddrInfo can be
+  a nullptr unique_ptr. Handle this explicitly by printing {nullptr} if
+  the rest of the function cannot be safely executed.
+  
+  Fix-by: Dan Noé <dpn@google.com>
 
-Daniel Stenberg (23 Jan 2016)
-- [Gregor Jasny brought this change]
+- [Dan Noé brought this change]
 
-  Fix typos detected by lintian
+  Add missing limits.h include from ares_getaddrinfo.c (#267)
   
-  Closes #32
+  This files references INT_MAX, but does not include limits.h. This can
+  cause a build failure on some platforms. Include limits.h if we have it.
+  
+  Fix-by: Dan Noé <dpn@google.com>
 
-- [Gregor Jasny brought this change]
+- [Andrew Selivanov brought this change]
 
-  Distribute all man pages
-
-- README.cares: s/I/Daniel
+  fix fuzzer docs and add missing getaddrinfo docs (#265)
   
-  ... and add a pointer to an existing version of the original area 1.1.1
-  package.a
-
-- read_tcp_data: don't try to use NULL pointer after malloc failure
+  There is a fix for a bit outdated clang fuzzer docs and ares_getaddrinfo docs.
   
-  CID 56884, pointed out by Coverity. We really should make this function
-  return an error code so that a malloc() failure can return back a major
-  failure.
+  Fix By: Andrew Selivanov (@ki11roy)
 
-- configure_socket: explicitly ignore return code
-  
-  CID 56889 in Coverity pointed out the return code from setsocknonblock()
-  is ignored, and this added typecast to (void) makes it explicit.
+- [Andrew Selivanov brought this change]
 
-- ahost: check the select() return code
+  Fix leak and crash in ares_parse_a/aaaa_reply (#264)
   
-  Fixes CID 137189, pointed out by Coverity
-
-David Drysdale (18 Jan 2016)
-- Fix buildconf on platforms using glibtoolize
+  * fix leak if naddress of particular type found
+  * fix segfault when wanted ttls count lesser than count of result records
+  * add fuzzer input files that trigger problems (from #263)
   
-  Commit c49a87eea538 changed buildconf to only check for
-  libtoolize, but missed a line
+  Reported-By: David Drysdale (@daviddrysdale)
+  Fix-By: Andrew Selivanov (@ki11roy)
 
-- Don't exit loop early leaving uninitialized entries
-  
-  Update for commit affc63cba875d.
+- [Andrew Selivanov brought this change]
+
+  fix segfault when parsing wrong type of record (#262)
   
-  The original patch from Gregor Jasny did not have the break
-  statement; I incorrectly added it to prevent continuing the loop.
-  However, the later entries in the array would then be left
-  uninitialized, causing problems for later cleanup.
+  Fixes segfault when trying to ares_parse_aaaa with AF_INET and vise versa.
   
-  So fix to match Gregor's original patch, with apologies.
+  Fix By: Andrew Selivanov (@ki11roy)
 
-Daniel Stenberg (18 Jan 2016)
-- buildconf: remove check for libtool, it only requires libtoolize
+- work around mingw compile failure
 
-David Drysdale (17 Jan 2016)
-- [Gregor Jasny brought this change]
+- c++ requires explicit casts
 
-  Use libresolv to initialize cares on iPhone targets
-  
-  On iPhone targets like iOS, watchOS or tvOS the file
-  /etc/resolv.conf cannot be used to configure cares.
+- support EnvValue on Windows by implementing setenv/unsetenv
+
+- [Andrew Selivanov brought this change]
+
+  getaddrinfo enhancements (#257)
   
-  Instead the resolver library is queried for configuration
-  values.
+  * Service support has been added to getaddrinfo.
+  * ares_parse_a/aaaa_record now share code with the addrinfo parser.
+  * Private ares_addrinfo structure with useful extensions such as ttls (including cname ttls),
+    as well as the ability to list multiple cnames in chain of lookups
   
-  CC: Yury Kirpichev <ykirpichev@yandex-team.ru>
-
-Daniel Stenberg (17 Jan 2016)
-- README: updated to new repo URL
+  Work By: Andrew Selivanov @ki11roy
 
-David Drysdale (14 Jan 2016)
-- [Lei Shi brought this change]
+- [Andrew Selivanov brought this change]
 
-  Fixing slow DNS lookup issue
+  fix ares__sortaddrinfo, use wrappers for sock_funcs (#258)
   
-  This patch is fixing the dns lookup issue due to dummy dns information
-  of a disconnected adapter(in my case is a bluetooth adapter). I changed
-  the dns lookup policy to try GetNetworkParams first because the
-  GetNetworkParams provides the most reliable dns information (lots of
-  checks were done by system). I also filter out inoperable adapter in
-  DNS_AdaptersAddresses in case GetNetworkParams fail.
+  Some socket functions weren't exposed for use by other areas of the library.  Expose
+  those and make use of them in ares__sortaddrinfo().
+  
+  Fix By: Andrew Selivanov (@ki11roy)
 
-- Merge pull request #30 from p-push/vs-2015
+- Fix c89 compilation support broken by .onion rejection changes
   
-  Support Visual Studio 2015
+  Move .onion check lower after all variables have been declared.
+  
+  Bug: #246
 
-Oleg Pudeyev (3 Jan 2016)
-- [Gisle Vanem brought this change]
+- [kedixa brought this change]
 
-  Support Visual Studio 2015
+  getaddrinfo: callback must be called on bad domain (#249)
+  
+  Due to an order of incrementing the remaining queries and calling ares_query, on a bad domain
+  the registered callback wouldn't be called.
+  
+  Bug: #248
+  Fixed-By: @kedixa
 
-David Drysdale (11 Nov 2015)
-- [Andrew Andkjar brought this change]
+- [Darrin W. Cullop brought this change]
 
-  added another version case to Makefile.msvc
+  Windows ARM/ARM64 requires AdvApi32 (#252)
   
-  nmake version 11.00.61030.0 resolves to CC_VERS_NUM = 110
-
-- Merge pull request #26 from bitbouncer/vs-2013
+  Fix link issues caused by missing library that appears to only be required on ARM (though
+  docs don't list this restriction). Doesn't hurt to require it everywhere.
   
-  added define for visual studio 2013
+  Bug: #251
+  Fixed-By: Darrin Cullop (@dwcullop)
 
-svante karlsson (25 Jun 2015)
-- added define for visual studio 2013
+- [kedixa brought this change]
 
-Jakub Hrozek (6 Nov 2014)
-- ares__read_line: free buf on realloc failure
+  getaddrinfo: avoid infinite loop in case of NXDOMAIN(#240) (#242)
+  
+  There are two possible causes for infinite loops fo NXDOMAIN, based on how many dots are in the domain name (one for < ARES_OPT_NDOTS and one for >= ARES_OPT_NDOTS), where it will repeat the same query over and over as the hquery->next_domain doesn't increment.
+  
+  Fix By: @kedixa
 
-- Destroy options if ares_save_options fails
+- Portability fix for ares__sortaddrinfo()
   
-  It's possible that, if ares_save_options failed, the opts structure
-  would contain some allocated memory. Calling ares_destroy_options in
-  this case is safe, because ares_save_options zeroes out the memory
-  initially.
+  replace uint32_t with unsigned int and socklen_t with ares_socklen_t
+  
+  By: Brad House
 
-- [David Drysdale brought this change]
+- [Khaidi Chu brought this change]
 
-  Continue loop if space for hostname not large enough
+  fix: init bufp before reject .onion to make it can be free correctly (#241)
   
-  When attempting to build a search domain from the local hostname
-  (used as a fallback when no other methods have given a search
-  domain), the code doubles the buffer size on each loop iteration.
+  When querying a .onion domain, it returns directly without setting bufp to NULL. A subsequent free() that occurs can cause a segmentation fault.
   
-  However, the loop previously had a WHILE_FALSE terminator so the continue
-  statement exited the loop rather than going round again.
-
-Daniel Stenberg (30 Oct 2014)
-- ares_getnameinfo.3: there is no ares_getaddrinfo
+  Fix By: Khaidi Chu (@XadillaX)
 
-David Drysdale (30 Sep 2014)
-- [Gregor Jasny brought this change]
+- [Andrew Selivanov brought this change]
 
-  Prevent tmpbuf from overrunning
+  Add ares__sortaddrinfo() to support getaddrinfo() sorted results (#239)
   
-  Fix Coverity error CID 56886.
+  This is a port of RFC 6724 compliant sorting function from Android Bionic project:
+  https://android.googlesource.com/platform/bionic/+/e919b116d35aa7deb24ddece69c491e24c3b0d6f/libc/netbsd/net/getaddrinfo.c
   
-  Signed-off-by: Gregor Jasny <gjasny@googlemail.com>
+  The latest version is essentially the same, except two additional parameters to test connection with (mark/uid):
+  https://android.googlesource.com/platform/bionic/+/master/libc/dns/net/getaddrinfo.c
+  
+  Please note that even that version has some restrictions. It doesn't support some rules from RFC 6724:
+  
+  Rule 3 (Avoid deprecated addresses)
+  Rule 4 (Prefer home addresses)
+  Rule 7 (Prefer native transport)
+  
+  Submitted By: Andrew Selivanov (@ki11roy)
 
-- [Gregor Jasny brought this change]
+- [Christian Ammer brought this change]
 
-  Re-start loop if select fails
+  Increase portability of `ares-test-mock-ai.cc` (#235)
   
-  Fix Coverity error CID 56882
+  * using portable ares_inet_pton and updated includes in ares-test-mock-ai
+  * forgot to remove deleted ares-test-ai.cc in Makefile.inc
   
-  Signed-off-by: Gregor Jasny <gjasny@googlemail.com>
+  Fix By: Christian Ammer (@ChristianAmmer)
 
-- [Gregor Jasny brought this change]
+- [Fabrice Fontaine brought this change]
 
-  Free temporary variable in error path
+  m4/xc-cc-check.m4: use XC_CHECK_BUILD_FLAGS (#236)
   
-  Fix Coverity CID 56890
+  Use XC_CHECK_BUILD_FLAGS instead of XC_CHECK_USER_FLAGS.
+  Otherwise it complains of CPPFLAGS in CFLAGS.
+  [Retrieved from:
+  https://git.buildroot.net/buildroot/tree/package/c-ares/0001-use_check_build_instead_of_check_user.patch]
   
-  Signed-off-by: Gregor Jasny <gjasny@googlemail.com>
+  Signed-off-by: Gustavo Zacarias <gustavo@zacarias.com.ar>
+  Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
+  Submitted by: Fabrice Fontaine
 
-- [Gregor Jasny brought this change]
+- [Christian Ammer brought this change]
 
-  Fix integer shift overflow if both tcp_socket and udp_socket are set
+  Bugfix for `ares_getaddrinfo` and additional unit tests (#234)
   
-  The problem occurs if at the start of the loop the sockindex is at the
-  last valid ARES_GETSOCK_MAXNUM position. If then both udp_socket and
-  tcp_socket are valid, sockindex gets incremented for UDP first and
-  points one entry behind the array for the tcp block.
-  So the fix is to check after every increment of sockindex if it is still
-  valid.
+  This PullRequest fixes a bug in the function add_to_addrinfo which task is to add new addrinfo items to the ai_next linked list. Also additional unit tests for testing ares_getaddrinfo will be added:
   
-  Fix Coverity error CID 56878
+  Additional mock server test classes (ares-test-mock-ai.cc):
+  MockTCPChannelTestAI
+  MockExtraOptsTestAI
+  MockNoCheckRespChannelTestAI
+  MockEDNSChannelTestAI
+  RotateMultiMockTestAI
+  NoRotateMultiMockTestAI
   
-  Signed-off-by: Gregor Jasny <gjasny@googlemail.com>
+  Additional live tests (ares-test-live-ai.cc):
+  LiveGetHostByNameV4
+  LiveGetHostByNameV6
+  LiveGetHostByNameV4AndV6
+  
+  Fix By: Christian Ammer (@ChristianAmmer)
 
-- [Gregor Jasny brought this change]
+- [Christian Ammer brought this change]
 
-  Null check before dereference
+  Remaining queries counter fix, additional unit tests for `ares_getaddrinfo` (#233)
   
-  Fix Coverity error CID 56880
+  Remaining queries counter fix, added tests (ParallelLookups,
+  SearchDomains, SearchDomainsServFailOnAAAA).  Removed unnecessary
+  if and commented code in test.
   
-  Signed-off-by: Gregor Jasny <gjasny@googlemail.com>
+  Fix By: Christian Ammer (@ChristianAmmer)
 
-Jakub Hrozek (28 Jul 2014)
-- [Gisle Vanem brought this change]
+- [Christian Ammer brought this change]
 
-  Comment in ares_ipv6.h
+  Add initial implementation for ares_getaddrinfo (#112)
+  
+  Initial implementation for ares_getaddrinfo().  It is NOT compliant with RFC6724, though
+  it is expected to come closer to conformance prior to the next release.
+  
+  Features not supported include sorted addresses and honoring of service and hints
+  parameters.
+  
+  Implementation by: Christian Ammer (@ChristianAmmer)
 
-David Drysdale (25 Jul 2014)
-- CONTRIBUTING: add file to indicate mailing list is preferred
+- [Ben Noordhuis brought this change]
 
-- Add -t u option to ahost
+  test: fix bad expectation in ipv6 localhost test (#227)
   
-  Add an option to allow specification of the AF_UNSPEC
-  address family.
+  The LiveGetLocalhostByAddrV6 test expected to see "localhost" in the
+  result when doing an address-to-name lookup for ::1 but on my system
+  that resolves to "ip6-loopback" because of this stanza in /etc/hosts:
+  
+      $ grep ^::1 /etc/hosts
+      ::1     ip6-localhost ip6-loopback
+  
+  Fix By: Ben Noordhuis (@bnoordhuis)
+  Bug: #85
 
-Jakub Hrozek (24 Jul 2014)
-- host_callback: Fall back to AF_INET on searching with AF_UNSPEC
+- [Ben Noordhuis brought this change]
+
+  ares_version.h: bump version (#230)
   
-  Previously, when an ares_gethostbyname() searched with AF_UNSPEC and the
-  first AF_INET6 call only returned CNAMEs, the host_callback never
-  retried AF_INET.
+  Version change not committed from maketgz.sh
   
-  This patch makes sure than on ARES_SUCCESS, the result of AF_INET6 is
-  taken as authoritative only if the result contains some addresses.
+  Bug: #229
 
-- [David Drysdale brought this change]
+Daniel Stenberg (24 Oct 2018)
+- ares_library_init_android.3: minor syntax edits, fixed AVAILABILITY
 
-  Move memset call below platform-specific declarations
+Version 1.15.0 (23 Oct 2018)
+
+Brad House (23 Oct 2018)
+- last minute 1.15.0 addition
+
+- [Ben Noordhuis brought this change]
+
+  Report ARES_ENOTFOUND for .onion domain names as per RFC7686. (#228)
   
-  A GitHub commenter [1] says that my recent change to ahost.c has
-  problems compiling on Windows + C89 platforms.
+  Quoting RFC 7686:
   
-  [1]  https://github.com/bagder/c-ares/commit/ee22246507c9#commitcomment-6587616
+      Name Resolution APIs and Libraries (...) MUST either respond
+      to requests for .onion names by resolving them according to
+      [tor-rendezvous] or by responding with NXDOMAIN.
+  
+      A legacy client may inadvertently attempt to resolve a .onion
+      name through the DNS. This causes a disclosure that the client
+      is attempting to use Tor to reach a specific service. Malicious
+      resolvers could be engineered to capture and record such leaks,
+      which might have very adverse consequences for the well-being
+      of the user.
+  
+  Bug: #196
+  Fix By: Ben Noordhuis @bnoordhuis
 
-- [David Drysdale brought this change]
+- prepare for c-ares 1.15.0 release
 
-  Update ahost man page to describe -s option.
+- AIX Build Fix
   
-  Commit ee22246507c9 added the -s <domain> option to the
-  ahost command, but neglected to update the man page to
-  describe it.
+  AIX attempts to include both nameser_compat.h and onameser_compat.h.  It appears
+  the proper fix is to define _USE_IRS so that only nameser_compat.h is used.
   
-  Also fix typo in description of -t option.
+  Bug: #224
+  Fix By: Brad House (@bradh352)
 
-- ares_parse_soa_reply: Do not leak rr_name on allocation failure
+- Fix crash in ares_dup() due to new ARES_OPT_RESOLVCONF
   
-  If ares_malloc_data failed, already allocated rr_name would go out of
-  scope.
+  ares_dup() calls ares_init_options() by making its own fake option
+  mask since the original mask isn't stored but ARES_OPT_RESOLVCONF
+  was always set, instead of conditionally set.  This caused a crash
+  because ares_strdup() isn't NULL-safe if no custom path was set.
+  
+  Made ares_dup() set ARES_OPT_RESOLVCONF conditionally.
+  
+  Fix By: Brad House (@bradh352)
 
-- [David Drysdale brought this change]
+- [Sarat Addepalli brought this change]
 
-  Don't override explicitly specified search domains
+  Add ares_init_options() configurability for path to resolv.conf file
   
-  Only set search domains from /etc/resolv.conf if there isn't a value
-  already present in the channel.
+  Add resolvconf_path to end of struct ares_options with ARES_OPT_RESOLVCONF option
+  so on Unix-like systems a custom path can be specified.  If no path is specified,
+  /etc/resolv.conf is used like normal.
+  
+  Fix By: Sarat Addepalli @SirR4T
+  Fixes Bug: #220
+  Review By: Brad House @bradh352
 
-- [David Drysdale brought this change]
+- remove stale variables
 
-  Allow specification of search domain in ahost
-  
-  Add the "-s domain" command line option to override the search
-  domains.
+- fix prototype name for ares_strsplit_free()
 
-Daniel Stenberg (12 May 2014)
-- Revert "ares_parse_aaaa_reply: fix leak when reply contains 1 alias and no address"
-  
-  This reverts commit 440110b303fdbfadb3ad53d30eeb98cc45d70451.
+- add missing prototype
 
-- [Frederic Germain brought this change]
+- simplify ares_strsplit() and create ares_strsplit_free() helper function
 
-  ares_parse_aaaa_reply: fix leak when reply contains 1 alias and no address
+- missing ares_strsplit.h from HHEADERS for inclusion in distribution
 
-- [Doug Kwan brought this change]
+- [Ruslan Baratov brought this change]
 
-  ares_build.h: fix building on 64-bit powerpc
+  Add CARES_BUILD_TOOLS CMake option (#214)
   
-  There are two issues.
+  Add ability to exclude building of tools (adig, ahost, acountry) in CMake.  This should also close #200.
   
-  1. gcc actually does not use __ppc__ and __ppc64__ but __PPC__ and
-  __PPC64__.  The tests of __ILP32__ and __LP64__ are sufficient for gcc.
+  Fix By: Ruslan Baratov (@ruslo)
+  Bug: #200
+
+- [flyingdutchman23 brought this change]
+
+  Style. Whitespace cleanup. (#213)
   
-  2. clang defines __GNU__ and defines both __ppc64__ and __ppc__ when
-  targeting ppc64.  This makes CARES_SIZEOF_LONG to be 4 on a ppc64 system
-  when building with clang.
+  Small whitespace cleanups.
   
-  My patch is two change the order of the checks so that we check the
-  64-bit case first.
-
-- refresh: updated now with automake 1.14
+  Fix By: @flyingdutchman23
 
-- [David Drysdale brought this change]
+- [John Schember brought this change]
 
-  single_domain: Invalid memory access for empty string input
+  Android: Support for domain search suffix (#211)
   
-  We noticed a small buglet in ares_search() when it gets an empty string
-  as input -- the single_domain() utility function in ares_search.c
-  accesses invalid memory (before the start of the string).
-
-Guenter Knauf (31 Aug 2013)
-- Fixed warning 'type specifier missing'.
+  Fixes issue #207. Uses LinkProperties.getDomains() to get a list of search domains and adds them to the suffix list.  This also adds a new helper function to split strings into an array based on multiple delimiters replacing multiple other functions for dealing with string splitting.
+  
+  Submitter: John Schember (@user-none)
+  Fixes: #207
+  Approved-by: Brad House (@bradh352)
 
-Daniel Stenberg (30 Aug 2013)
-- [Tor Arntsen brought this change]
+- [afalin brought this change]
 
-  ares_rules.h: CARES_SIZEOF_LONG doesn't exist anymore, don't test for it
+  Improve DNS suffixes extracting from WinNT registry (#202)
   
-  It was removed in f19387dd72432
-
-- nowarn: use <limits.h> instead of configure for size of long
+  Join all global and connection specific suffix lists. Use 'HKLM\Software\Policies\Microsoft\Windows NT\DNSClient\SearchList', 'HKLM\System\CurrentControlSet\Services\Tcpip\Parameters\Domain' as global suffix lists.
   
-  This makes the header file much more multi-arch friendly and can be used
-  as-is with both 32 bit and 64 bit builds.
+  Fix By: @afalin
 
-- timeoffset: made static and private
+- Be consistent with indention in CMakeLists.txt
   
-  ares__timeoffset() was only used once within this single source file
-
-- timeadd: make static
+  The imported TRANSFORM_MAKEFILE_INC function from curl used space indention
+  but the rest of the file used tabs.  Go ahead and make it tabs for
+  consistency as well.
   
-  ares__timeadd() was only ever used from within the same source
+  Committed By: Brad House
 
-Yang Tse (18 Jul 2013)
-- xc-am-iface.m4: comments refinement
+- [flyingdutchman23 brought this change]
 
-- configure: fix 'subdir-objects' distclean related issue
+  Fix modern gcc warning: argument to 'sizeof' in 'strncpy' call is the same expression as the source
   
-  See XC_AMEND_DISTCLEAN comments for details.
+  Silence warning about using src to determine number of bytes to copy.
+  In this case it doesn't matter whether it is `src` or `dest`. So there
+  is no functionality change.
+  
+  Bug: #210
+  Fix By: @flyingdutchman23
 
-- configure: automake 1.14 compatibility tweak (use XC_AUTOMAKE)
+- [Andi Schnebinger brought this change]
 
-- xc-am-iface.m4: provide XC_AUTOMAKE macro
+  fix stringop-overflow warning of GCC (#201)
+  
+  When using a modern GCC to compile c-ares, there is a stringop-overflow warning.
+  This patch simply silences the false-positive warning, there is no actual code flaw.
+  
+  Bug: https://github.com/c-ares/c-ares/pull/201
+  Fixed By: Andi Schnebinger @Iniesta8
 
-Daniel Stenberg (12 May 2013)
-- gitignore: ignore all ares_*pdf but also CHANGES.dist
+GitHub (18 May 2018)
+- [David Drysdale brought this change]
 
-- bump: start working towards 1.10.1
+  travis: do coverage in "coverage" build (#195)
+  
+  Fixes #194, a mistake from commit a255081f2c3c ("travis: Only do
+  coverage/distcheck on normal build")
 
-Version 1.10.0 (12 May 2013)
+Brad House (17 May 2018)
+- [Brad Spencer brought this change]
 
-Daniel Stenberg (12 May 2013)
-- RELEASE-NOTES: two more bug fixes
+  Apply the IPv6 server blacklist to all nameserver sources, not just Windows (#193)
+  
+  For #164, I mentioned that it seemed like the IPv6 nameserver blacklist should apply to all OSes. In a mailing list post, @bradh352 agreed and suggested that I file a PR to make it so.
+  
+  This moves the blacklist check from being Windows-specific to being a general feature of config_nameservers(), no matter the nameserver source. It also simplifies the ares_ipv6_server_blacklisted() implementation to not parse and re-parse the blacklisted IPv6 addresses from strings on every check. I think they're almost as easy to read as a sequence of hex bytes in an array initializer, and it's definitely less work on each trip through the code.
+  
+  Fix By: Brad Spencer @b-spencer
+  PR: https://github.com/c-ares/c-ares/pull/193
 
-- [Keith Shaw brought this change]
+- [Brad Spencer brought this change]
 
-  ares_set_servers_csv: fixed IPv6 address parsing
+  Fix warnings emitted by MSVC when using -W4 (#192)
   
-  Fixed bug that caused the last part of an IPv6 address to be parsed as
-  the port number when the last part is all numeric.
+  These changes fix a few warnings emitted by recent versions of MSVC when compiling with -W4. Half of the changes are in Windows-specific code, and the other half should be safe no matter the compiler or OS.
+  
+  The allocation function change is probably the only one that needs explanation. MSVC gives warnings about the function pointers not being stable across DLL boundaries or something to that effect, so for Windows, I've made them be called indirectly, which at least made the compiler happy. I can't say I've tested every linking combination on Windows with them before or after the change, but it seems harmless.
+  
+  Fix By: Brad Spencer @b-spencer
+  PR: https://github.com/c-ares/c-ares/pull/192
 
-- nroff: fix two syntax mistakes
+- [David Hotham brought this change]
+
+  Prevent changing name servers while queries are outstanding (#191)
   
-  ares_parse_a_reply and ares_parse_aaaa_reply both had two \fB instead of
-  \fP
+  Changing name servers doesn't work, per #41.  Better to return an error code than to crash.
   
-  Reported-by: Alexander Klauer
-  Bug: http://c-ares.haxx.se/mail/c-ares-archive-2013-03/0010.shtml
+  Fix-by: David Hotham @dimbleby
 
-- [Alex Loukissas brought this change]
+David Drysdale (15 May 2018)
+- [Tobias Nießen brought this change]
 
-  build: fix build on msvc11
+  Fix comment in ares_rules.h (#189)
 
-- Makefile.am: increment -version-info for 1.10.0 release
+Brad House (6 May 2018)
+- [Brad Spencer brought this change]
 
-- README: remove unnecessary comment
-
-- ares_version.h: copyright end range year is now 2013
+  Harden and rationalize c-ares timeout computation (#187)
+  
+  * Harden and rationalize c-ares timeout computation
+  * Remove the rand() part of the timeout calculation completely.
+  
+  When c-ares sends a DNS query, it computes the timeout for that request as follows:
+  
+  timeplus = channel->timeout << (query->try_count / channel->nservers);
+  timeplus = (timeplus * (9 + (rand () & 7))) / 16;
+  I see two issues with this code. Firstly, when either try_count or channel->timeout are large enough, this can end up as an illegal shift.
+  
+  Secondly, the algorithm for adding the random timeout (added in 2009) is surprising. The original commit that introduced this algorithm says it was done to avoid a "packet storm". But, the algorithm appears to only reduce the timeout by an amount proportional to the scaled timeout's magnitude. It isn't clear to me that, for example, cutting a 30 second timeout almost in half to roughly 17 seconds is appropriate. Even with the default timeout of 5000 ms, this algorithm computes values between 2812 ms and 5000 ms, which is enough to cause a slightly latent DNS response to get spuriously dropped.
+  
+  If preventing the timers from all expiring at the same time really is desirable, then it seems better to extend the timeout by a small factor so that the application gets at least the timeout it asked for, and maybe a little more. In my experience, this is common practice for timeouts: applications expect that a timeout will happen at or after the designated time (but not before), allowing for delay in detecting and reporting the timeout. Furthermore, it seems like the timeout shouldn't be extended by very much (we don't want a 30 second timeout changing into a 45 second timeout, either).
+  
+  Consider also the documentation of channel->timeout in ares_init_options():
+  
+  The number of milliseconds each name server is given to respond to a query on the first try. (After the first try, the timeout algorithm becomes more complicated, but scales linearly with the value of timeout.) The default is five seconds.
+  
+  In the current implementation, even the first try does not use the value that the user supplies; it will use anywhere between 56% and 100% of that value.
+  
+  The attached patch attempts to address all of these concerns without trying to make the algorithm much more sophisticated. After performing a safe shift, this patch simply adds a small random timeout to the computed value of between 0 ms and 511 ms. I could see limiting the random amount to be no greater than a proportion of the configured magnitude, but I can't see scaling the random with the overall computed timeout. As far as I understand, the goal is just to schedule retries "not at the same exact time", so a small difference seems sufficient.
+  
+  UPDATE: randomization removed.
+  
+  Closes PR #187
+  Fix by: Brad Spencer
 
-- RELEASE-NOTES: synced with fb0737f3a0a1c37
+- distribute ares_android.h
+  
+  Distribute ares_android.h when a release distribution package is
+  created.
+  
+  Reported By: Andrey Khranovsky
+  Bug: https://c-ares.haxx.se/mail/c-ares-archive-2018-04/0000.shtml
 
-- [Paul Saab brought this change]
+- ares_set_servers_csv() on failure should not leave channel in a bad state
+  
+  If bad data is passed to ares_set_servers_csv() or
+  ares_set_servers_ports_csv() it will clear the existing channel
+  configured DNS servers, then a call to ares_send() will fail due
+  to a bad malloc which may have undefined behavior.
+  
+  The fix now only clears existing servers on success.  An additional
+  sanity check was added in ares_send() to ensure nservers >= 1 or
+  will result in ARES_ESERVFAIL.
+  
+  Bug: https://c-ares.haxx.se/mail/c-ares-archive-2018-03/0000.shtml
+  Reported-by: Francisco Sedano Crippa
 
-  ares_parse_aaaa_reply: Plug memory leak
+- docs: Not all manpages are listed
   
-  This change is similar to ares_parse_a_reply.c in commit
-  bffd67f16a8f42fe6dbf79ab2e39d92eea05c8a6
+  Some docs aren't installed or not showing up on
+  https://c-ares.haxx.se/docs.html
+  due to not being listed in Makefile.inc.  Add missing docs and
+  ensure docs are alphabetized.
 
-- [Patrick Valsecchi brought this change]
+Version 1.14.0 (16 Feb 2018)
 
-  ares_parse_txt_reply: return a ares_txt_reply node for each sub-string
-  
-  Previously, the function would wrongly return all substrings merged into
-  one.
+Daniel Stenberg (16 Feb 2018)
+- ares_android.c: fix warning: ISO C forbids an empty translation unit
 
-- [Alexander Klauer brought this change]
+- RELEASE-NOTES: some more work we did and people who helped
 
-  library init: documentation update
+Brad House (16 Feb 2018)
+- travis: skip Autotools style testing for cmake
   
-  This commit updates the documentation of ares_library_init() and
-  ares_library_cleanup() with regard to the newly introduced reference
-  counting of initializations and deinitializations.
+  Fix cmake test build by skipping autotools portion of test script.
 
-- [Alexander Klauer brought this change]
+- travis: standardize CMake test off of Autotools tests
+  
+  Instead of running 'make test', run the tests directly like autotools
+  does.  It provides more verbose output.
 
-  library init: be recursive
+- travis: Enable building tests for CMake
   
-  Previously, a single call to ares_library_cleanup() would deinitialise
-  the c-ares library, regardless of how many times ares_library_init() was
-  called. This behaviour may cause problems in programs linking two or
-  more libraries which, in turn, use c-ares. The present commit fixes this
-  problem, deinitializing the library only after a number of calls to
-  ares_library_cleanup() matching the number of calls to
-  ares_library_init().
+  Travis should auto-build and run tests for cmake builds now that
+  PR #168 is merged.
 
-- [Patrick Valsecchi brought this change]
+- fix version in pkgconfig
 
-  protocol parsing: check input data stricter
-  
-  ... so that bad length fields aren't blindly accepted
-  
-  Bug: http://c-ares.haxx.se/mail/c-ares-archive-2013-04/0016.shtml
+- Add version update to CMakeLists in maketgz
 
-Guenter Knauf (11 Apr 2013)
-- Create ares_build.h when buidling from Git.
+- Release prep.  Add support for pkgconfig in cmake, set versions appropriately
 
-- Added -DCARES_STATICLIB to CFLAGS.
-  
-  Currently this static makefile does only support building the
-  static library libcares.a.
+Gregor Jasny (15 Feb 2018)
+- CMake: Add tests
 
-Daniel Stenberg (8 Apr 2013)
-- [Alexander Klauer brought this change]
+Brad House (14 Feb 2018)
+- [Gregor Jasny brought this change]
 
-  .gitignore: ignore patch files
-  
-  This commit adds a line to .gitignore to the effect that patch files
-  generated by 'git format-patch' are excluded from the repository.
+  Use cmake3 package provided by Ubuntu (#182)
 
-- [Alexander Klauer brought this change]
+- Cmake 3.1 instead of 3.2.1 should be the minimum
 
-  ares_destroy() documentation: no new requests
-  
-  Clarify that no new requests may be added to a resolver channel that is
-  currently being destroyed.
+- Update RELEASE-NOTES and RELEASE-PROCEDURE.md to prepare for next release
 
-- [Alexander Klauer brought this change]
+- get rid of c++ style comments
 
-  Documentation: properly document ARES_ECANCELLED
-  
-  This commit clarifies the behaviour of ares_cancel() with respect to
-  callbacks and adds missing documentation of ARES_ECANCELLED to the man
-  pages of the affected functions.
+- Use trusty for all builds, precise is EOL.  Update clang and cmake versions.
 
-- [Alexander Klauer brought this change]
+- Current CMakeLists.txt doesn't support 2.8.12 anymore, we need to bump the version to 3.2.1 minimum
 
-  ares_cancel(): cancel requests safely
-  
-  An invocation of ares_cancel() walks through the request list, calling
-  the callbacks of all pending requests on a channel. Previously, if such
-  a callback added a new request to the channel, the request list might
-  not end up empty, causing an abort by assertion failure. The present
-  commit ensures that precisely all requests present upon entry of
-  ares_cancel() are cancelled, and that adding new requests through
-  callbacks is safe.
+- Re-organize sections in INSTALL.md and add CMake section
 
-Yang Tse (10 Mar 2013)
-- ares.h: stricter CARES_EXTERN linkage decorations logic
-  
-  No API change involved.
+- [Sergey Kolomenkin brought this change]
 
-- ares_build.h.dist: enhance non-configure GCC ABI detection logic
-  
-  GCC specific adjustments:
-  
-  - check __ILP32__ before 32 and 64bit processor architectures in
-    order to detect ILP32 programming model on 64 bit processors
-    which, of course, also support LP64 programming model, when using
-    gcc 4.7 or newer.
-  
-  - keep 32bit processor architecture checks in order to support gcc
-    versions older than 4.7 which don't define __ILP32__
-  
-  - check __LP64__ for gcc 3.3 and newer, while keeping 64bit processor
-    architecture checks for older versions which don't define __LP64__
+  remove compilation warnings in MSVC (#47)
 
-Daniel Stenberg (9 Mar 2013)
-- ares.h: there is no ares_free_soa function
+- document handling of timeouts for ares_process and ares_process_fd to close PR #57
 
-Yang Tse (9 Mar 2013)
-- Makefile.am: empty AM_LDFLAGS definition for automake 1.7 compatibility
+- As per Issue #155, since we do not require gethostname() during init, if it fails, there's no reason for init to fail as it is only used to populate the domain
 
-- ares_inet_ntop.3: s/socklen_t/ares_socklen_t
+GitHub (7 Feb 2018)
+- [David Drysdale brought this change]
 
-- configure: use XC_LIBTOOL for portability across libtool versions
+  Document WSAStartup requirement (#180)
 
-- xc-lt-iface.m4: provide XC_LIBTOOL macro
+David Drysdale (6 Feb 2018)
+- [Antonio Tajuelo brought this change]
 
-- Makefile.am: use AM_CPPFLAGS instead of INCLUDES
+  Added coderelease.io badge to readme.md for letting people subscribe to new versions (#174)
 
-- inet_ntop.c: s/socklen_t/ares_socklen_t
+- [Sheel Bedi brought this change]
 
-- inet_ntop.c: s/socklen_t/ares_socklen_t for portability
+  Update year in LICENSE.md to 2018 (#170)
 
-Daniel Stenberg (19 Feb 2013)
-- ares.h: s/socklen_t/ares_socklen_t for portability
+GitHub (4 Feb 2018)
+- [David Drysdale brought this change]
 
-- ares_inet_ntop.3: 4th argument is socklen_t!
+  travis: use VM not container for {L,A}SAN builds (#177)
+  
+  As per https://github.com/travis-ci/travis-ci/issues/9033, container
+  based builds do not currently allow ptrace, which is used by LSAN and
+  ASAN.
 
-- spell inet correctly!
+Brad House (3 Feb 2018)
+- [acthompson-google-com brought this change]
 
-- ares_inet_pton/ntop: cleanup
+  Android JNI code leaks local references in some cases (#175)
   
-  Make sure that the symbols are always exported and present in c-ares.
+  * Add Google LLC to AUTHORS.
   
-  Make the headers prefixed with 'ares'.
+  * android: Explicitly delete all JNI local references, and cache JNI method IDs at initialization.
   
-  Removed the inet_ntop.h version as it no longer features any content.
+  * android: Only return ARES_ENOTINITIALIZED on failures in initialization code.
 
-- ares_inet_ntop/ares_inet_pton: added man pages
+Gregor Jasny (2 Jan 2018)
+- Embed fused Google Test 1.8.0
 
-Yang Tse (15 Feb 2013)
-- [Gisle Vanem brought this change]
+Brad House (21 Dec 2017)
+- [John Schember brought this change]
 
-  curl_setup_once.h: definition of HAVE_CLOSE_S defines sclose() to close_s()
+  android: Check returns for obj and classes are not NULL. Document API levels for various Android functions and objects used. (#166)
 
-- [Gisle Vanem brought this change]
+- CARES_CHECK_TYPE should reference variable so a warning is not produced for -Werror compatibility
 
-  config-dos.h: define HAVE_CLOSE_S for MSDOS/Watt-32
+- [Brad Spencer brought this change]
 
-- [Gisle Vanem brought this change]
+  Fix computation of IPv6 blacklist mask for values of netmask > 8. (#164)
 
-  config-dos.h: define strerror() to strerror_s_() for High-C
+David Drysdale (14 Dec 2017)
+- travis: Only do coverage/distcheck on normal build
 
-Daniel Stenberg (13 Feb 2013)
-- ares_get_datatype: removed unused function
-  
-  it was also wrongly named as internal functions require two underscores
+- travis: only do pip install on Linux
 
-- ares__bitncmp: use two underscores for private functions
+- travis: only test in IPv4 mode
   
-  It used a single one previously making it look like a public one
+  Travis' Trusty environment does not support IPv6.
 
-- ares__generate_new_id: moved to ares_query.c
-  
-  ... and ares__rc4 is turned into a local static function.
+- test: allow restriction to one IP address family
 
-- ares__swap_lists: make private and static
-  
-  ... since there's only one user, make it static within ares_process.c
+- [Roman Teterin brought this change]
 
-Yang Tse (13 Feb 2013)
-- Makefile.msvc: add four VS version strings
+  Fix a typo in init_by_resolv_conf (#160)
 
-Daniel Stenberg (13 Feb 2013)
-- ares_expand_name.3: clarify how to free the data
+Brad House (11 Dec 2017)
+- @gvanem says MSVC -RTCc option fails, looks erroneous to me, but the additional mask is harmless
 
-Yang Tse (30 Jan 2013)
-- zz40-xc-ovr.m4: fix 'wc' detection - follow-up 2
+- Fix some other mingw warnings
+
+- Issue #143, get rid of windows build warning due to passing 'char **' to argument expecting 'const char **'
+
+- [Gregor Jasny brought this change]
+
+  Distribute CMake files (#130)
+
+- Android variants may not have __system_property_get
   
-  - Fix a pair of single quotes to double quotes.
+  Some android systems like ARM64 may not have the __system_property_get
+  symbol in libc (but still have it in the public headers).  Detect this
+  condition at build time.  The __system_property_get method of retrieving
+  name servers is deprecated as of Oreo so should strictly be a fallback
+  mechanism anyhow.
+
+David Drysdale (9 Nov 2017)
+- [David Hotham brought this change]
+
+  Wrong function name throughout man page (#154)
+
+- ares_data.c: iterate through substructs when freeing
   
-  URL: http://curl.haxx.se/mail/lib-2013-01/0355.html
-  Reported by: Tor Arntsen
+  Previous code recursed into substructures, which makes it more likely
+  that large/heavily-nested responses could use up lots of stack.
 
-- zz40-xc-ovr.m4: fix 'wc' detection - follow-up
+- test: test ares_free_data on long chain of structs
+
+- [Felix Yan brought this change]
+
+  Fix a typo in inet_ntop.c (#151)
+
+Daniel Stenberg (29 Sep 2017)
+- ares_gethostbyname.3: fix callback status values
   
-  - Take into account that 'wc' may return leading spaces and/or tabs.
+  - ARES_ENOTFOUND means the _name_ wasn't found
   
-  - Set initial IFS to space, tab and newline.
+  - ARES_ENODATA can be returned when a resolve fails
+  
+  Reported-by: Jakub Hrozek
+  Bug: https://c-ares.haxx.se/mail/c-ares-archive-2011-06/0012.shtml
 
-- zz40-xc-ovr.m4: fix 'wc' detection
+Brad House (28 Sep 2017)
+- [John Schember brought this change]
+
+  Fix DNS server lookup breaking with Android O due to Android removing access to net.dns# system properties. (#148)
   
-  - Take into account that 'wc' may return leading spaces.
+  As of Android 8 (Oreo) access to net.dns# has been removed (https://developer.android.com/about/versions/oreo/android-8.0-changes.html). The reasoning given is that it, "improves privacy on the platform". Currently c-ares uses this to get the list of DNS servers.
   
-  - Set internationalization behavior variables.
+  Now the only way to access the DNS server list is by using the Connectivity Manager though Java. This adds the necessary JNI code to use the Connectivity Manager and pull the DNS server list. The old way using __system_property_get with net.dns# remains for compatibilty.
   
-  Tor Arntsen analyzed and reported the issue.
+  Using the Connectivity Manager requires the ACCESS_NETWORK_STATE permission to be set on the app. Existing applications most likely are not setting this and keeping the previous method as a fallback will at the very least ensure those apps don't break on older versions of Android. They will need to add this permission for Android 8 compatibility.
   
-  URL: http://curl.haxx.se/mail/lib-2013-01/0351.html
+  Included in the patch are two initalization functions which are required. The JVM must be registered as well as the Connectivity Manager itself. There is no way to get the Connectivity Manager except though Java. Either being passed down to C directly or by passing in an Android Context which can be used to get the Connectivity Manager. Examples are provided in the documentation.
 
-- zz40-xc-ovr.m4: check another three basic utilities
+- [Konstantinos Sofokleous brought this change]
 
-- zz40-xc-ovr.m4: 1.0 interface stabilization
+  allow linking against the static msvc runtime library (#133)
   
-  - Stabilization results in 4 public interface m4 macros:
-    XC_CONFIGURE_PREAMBLE
-    XC_CONFIGURE_PREAMBLE_VER_MAJOR
-    XC_CONFIGURE_PREAMBLE_VER_MINOR
-    XC_CHECK_PATH_SEPARATOR
-  - Avoid one level of internal indirection
-  - Update comments
-  - Drop XC_OVR_ZZ40 macro
+  allow linking against the static msvc runtime library
 
-- zz40-xc-ovr.m4: emit witness message in configure BODY
-  
-  This avoids witness message in output when running configure --help,
-  while sending the message to config.log for other configure runs.
+- [Gergely Nagy brought this change]
 
-- zz40-xc-ovr.m4: truly do version conditional overriding
+  Force using the ANSI versions of WinAPI functions (#142)
   
-  - version conditional overriding
-  - catch unexpanded XC macros
-  - fix double words in comments
+  When compiling c-ares with a build system that defines UNICODE,
+  bad versions of WinAPI functions are used causing failures or even
+  crashes. When windows.h is included in MBCS mode (like in the default
+  build system), the ..A versions are the same as using the one without
+  any suffix.
 
-- zz40-xc-ovr.m4: fix variable assignment of subshell output bashism
-  
-  Tor Arntsen analyzed and reported the issue.
-  
-  URL: http://curl.haxx.se/mail/lib-2013-01/0306.html
+- [cmake] build fix on Solaris
 
-- zz40-xc-ovr.m4: reinstate strict AC_REQUIRE macro dependencies
+GitHub (11 Sep 2017)
+- [Brad House brought this change]
 
-- zz40-xc-ovr.m4: avoid double single-quote usage
+  Win32 exclude legacy ipv6 subnets (#144)
+  
+  win32 ipv6: add infrastructure to exclude ipv6 subnets that are known to cause issues
 
-- zz40-xc-ovr.m4: parentheses balancing of 'case' statements
+- [David Drysdale brought this change]
+
+  windows: only look for ancient compilers (#146)
   
-  m4 quadrigraph shell comment technique allows proper autoconf
-  parentheses balancing in shell 'case' statements. The presence
-  of unbalanced parentheses may otherwise trigger expansion bugs.
+  Also drop the use of a versioned output directory; just use
+  .\msvc
 
-- zz40-xc-ovr.m4: internals overhauling
+- [David Drysdale brought this change]
+
+  ares_init_options.3: match up sock_state_cb args (#141)
   
-  - Update comments
-  - Execute commands in subshells
-  - Faster path separator check
-  - Fix missing 'test' command
-  - Rename private macros
-  - Minimize AC_REQUIRE usage
+  Fixes #140
 
-- zz40-xc-ovr.m4: redirect errors and warnings to stderr
+Daniel Stenberg (25 Aug 2017)
+- [Anna Henningsen brought this change]
 
-- configure: use XC_CONFIGURE_PREAMBLE early checks
+  gethostbyaddr: fail with `ECANCELLED` for `ares_cancel()`
   
-  Some basic checks we make were placed early enough in generated
-  configure script when using autoconf 2.5X versions. Newer autoconf
-  versions expand these checks much further into the configure script,
-  rendering them useless. Using XC_CONFIGURE_PREAMBLE fixes placement
-  of early intended checks across all our autoconf supported versions.
+  When `ares_cancel()` was invoked, `ares_gethostbyaddr()`
+  queries would fail with `ENOTFOUND` instead of `ECANCELLED`.
+  
+  It seems appropriate to treat `ares_cancel()` like `ares_destroy()`,
+  but I would appreciate review of the correctness of this change.
+  
+  Ref: https://github.com/nodejs/node/issues/14814
+  
+  Closes #138
 
-- zz40-xc-ovr.m4: provide XC_CONFIGURE_PREAMBLE macro
+David Drysdale (18 Aug 2017)
+- [David Hotham brought this change]
 
-- configure: autotools compatibility fixes - step I
+  support most recent Visual Studio 2017
+
+Brad House (26 Jul 2017)
+- Preserve original DNS server order on Windows for equal metrics.
   
-  Fix proper macro expansion order across autotools versions for
-  C compiler and preprocessor program checks.
+  qsort is not stable, in order to make it stable we need to record
+  the original index and add it as a secondary sort value when the
+  metrics are equal to prevent using DNS servers that may not work
+  at all as reported by some users.
 
-- configure: fix automake 1.13 compatibility
+David Drysdale (15 Jul 2017)
+- [Anna Henningsen brought this change]
+
+  ares_parse_naptr_reply: make buffer length check more accurate
   
-  Tested with:
+  9478908a490a6bf009ba58d81de8c1d06d50a117 introduced a length check
+  for records parsed by `ares_parse_naptr_reply()`. However, that
+  function is designed to parse replies which also contain non-NAPTR
+  records; for A records, the `rr_len > 7` check will fail as there
+  are only 4 bytes of payload.
+  In particular, parsing ANY replies for NAPTR records was broken
+  by that patch.
   
-  buildconf: autoconf version 2.69
-  buildconf: autom4te version 2.69
-  buildconf: autoheader version 2.69
-  buildconf: automake version 1.13.1
-  buildconf: aclocal version 1.13.1
-  buildconf: libtool version 2.4
-  buildconf: GNU m4 version 1.4.16
+  Fix that by moving the check into the case in which it is already
+  known that the record is a NAPTR record.
 
-- ares_private.h: use again memdebug.h instead of curl_memdebug.h
+- appveyor: run dnsdump as a sanity check
 
-- configure.ac: replace AM_CONFIG_HEADER with AC_CONFIG_HEADERS
+- travis: run dnsdump as a sanity check
+
+- test: use ares_free_string() throughout
   
-  automake 1.13 errors if AM_CONFIG_HEADER is used in configure script.
+  As pointed out by Gisle Vanem in #125.
 
-- cares-override.m4: provide AC_CONFIG_MACRO_DIR definition conditionally
+Daniel Stenberg (3 Jul 2017)
+- RELEASE-PROCEDURE.md: how to release
   
-  Provide a 'traceable' AC_CONFIG_MACRO_DIR definition only when using
-  an autoconf version that does not provide it, instead of what we were
-  doing up to now of providing and overriding AC_CONFIG_MACRO_DIR for
-  all autoconf versions.
+  Fixes #115
+  Closes #116
 
-- ares_private.h: use curl_memdebug.h instead of memdebug.h
+David Drysdale (2 Jul 2017)
+- test: Build dnsdump on Windows too
+  
+  Thanks to Gisle Vanem for showing the way:
+  https://github.com/c-ares/c-ares/commit/b701af8a24cf9d173b1dbe5faedcea34642e92da#commitcomment-22830845
 
-- vc6cares.dsp: add ares_create_query.c and ares_parse_soa_reply.c
+Brad House (26 Jun 2017)
+- [Christian Ammer brought this change]
 
-- cares-functions.m4: improve gethostname arg 2 data type check
+  fix statement like #define - ares ssize_t define had a trailing semicolon (#120)
 
-- setup_once.h: HP-UX specific 'bool', 'false' and 'true' definitions.
+David Drysdale (21 Jun 2017)
+- test: distribute the fuzzcheck.sh script
   
-  Also reverts commit bceb40095a
+  The TESTS target runs fuzzcheck.sh so make sure it is included
+  in the distributed tarball.
+  
+  (The test itself will be pointless when run on a distribution, because
+  the fuzzing corpus directories are not shipped, but at least this
+  means that `make -C test test` should work.)
 
-- configure: check if compiler halts on function prototype mismatch
+- test: run the name-parsing corpus check too
 
-- cares-functions.m4: add gethostname arg 2 data type check and definition
-
-- cares-functions.m4: update thread-safeness detection of getaddrinfo()
-  
-  Take in account that POSIX standard Issue 7 drops h_errno support. Now, we also
-  consider getaddrinfo() to be thread-safe when (_POSIX_C_SOURCE >= 200809L) or
-  (_XOPEN_SOURCE >= 700) independently of whether h_errno exists or not.
+Daniel Stenberg (21 Jun 2017)
+- dist: don't build/ship PDF versions in release archives
   
-  Take in account that h_errno might be a modifiable lvalue not defined as
-  a C preprocessor macro.
+  ... experience says very few read them and they can still get build by
+  those who want them.a
 
-- setup_once.h: HP-UX <sys/socket.h> issue workaround
-  
-  Issue: When building a 32bit target with large file support HP-UX
-  <sys/socket.h> header file may simultaneously provide two different
-  sets of declarations for sendfile and sendpath functions, one with
-  static and another with external linkage. Given that we do not use
-  mentioned functions we really don't care which linkage is the
-  appropriate one, but on the other hand, the double declaration emmits
-  warnings when using the HP-UX compiler and errors when using modern
-  gcc versions resulting in fatal compilation errors.
-  
-  Mentioned issue is now fixed as long as we don't use sendfile nor
-  sendpath functions.
+- ares_version.h: bump version
 
-- setup_once.h: refactor inclusion of <unistd.h> and <sys/socket.h>
-  
-  Inclusion of these two header files now done in setup_once.h
+Version 1.13.0 (20 Jun 2017)
 
-- Header inclusion clean-up
-  
-  Remove header inclusions already done in setup_once.h
+Daniel Stenberg (20 Jun 2017)
+- RELEASE-NOTES: 1.13.0
 
-- setup_once.h: HP-UX specific TRUE and FALSE definitions
+- ares_set_socket_functions.3: added in 1.13.0
+
+David Drysdale (18 Jun 2017)
+- ares_parse_naptr_reply: check sufficient data
   
-  Some HP-UX system headers require TRUE defined to 1 and FALSE to 0.
+  Check that there is enough data for the required elements
+  of an NAPTR record (2 int16, 3 bytes for string lengths)
+  before processing a record.
 
-- ares_timeout.c: fix compiler warning
+- test: Feed in short NAPTR
 
-- ares_create_query.c: IRIX compilation fix
+- test: Add fuzz input with short NAPTR
 
-- c-ares/nameser.h: add some T_* defines for ns_t_* values
+- test: add ares_parse_naptr_reply to fuzzer
 
-Daniel Stenberg (7 Nov 2012)
-- Revert "ares_parse_aaaa_reply: fix memory leak"
-  
-  This reverts commit 50f25d8a4b2d16f4c5e0ef620238688b7a315c7a.
+- [noiz brought this change]
 
-- ares_parse_aaaa_reply: fix memory leak
+  Update ares.h to support compiling with QNX
+
+- [Dionna Glaze brought this change]
+
+  Simple changes to appease stricter compilers.
   
-  an allocated buffer was not freed in the successful case.
+  ares_process.c uses htonl, which needs <arpa/inet.h> included.
+  ares_getnameinfo.c uses a dynamically selected format string for
+  sprintf, which -Wformat-literal doesn't like. Usually one would use
+  inttypes.h and a format string "%" PRIu32, but C99 is too new for some
+  supported platforms.
 
-- [Gisle Vanem brought this change]
+GitHub (16 Jun 2017)
+- [Gregor Jasny brought this change]
 
-  adig: perror() doesn't work for socket errors on windows
+  CMake: Emulate interface library on import (#108)
   
-  ... so print the SOCKERRNO instead
+  Closes: #104
+  Signed-off-by: Gregor Jasny <gjasny@googlemail.com>
 
-- get_DNS_AdaptersAddresses: fix IPv6 parsing
+Brad House (6 Jun 2017)
+- [ChristianAmmer brought this change]
+
+  Added support for Windows DNS Suffix Search List (#93)
   
-  Use of the wrong define made the function not parse IPv6 addresses
-  properly.
+  This change solves issue #53.
   
-  Bug: http://c-ares.haxx.se/mail/c-ares-archive-2012-06/0028.shtml
-  Reported by: Saúl Ibarra Corretgé
-
-- version: bumped to 1.10.0
+  Support for suffix search lists was already built in for Linux. The search list could be set via set_search. With this change the suffix search list from Windows is read from the registry and then set into the ares configuration via set_search. There are two sources for the search list:
   
-  Due to the newly added function: ares_create_query()
-
-- AUTHORS: synced with 83093ac450
+  The global DNS suffix search list.
+  The primary and connection specific DNS suffixes if the global is not available.
   
-  Added 21 authors since this document was last updated
-
-- ares_create_query.3: mention when this is added
-
-- [hpopescu@ixiacom.com brought this change]
-
-  Added new feature (rfc2671)
+  Contributed by @ChristianAmmer
 
-- code police: fix indents, < 80 columns, reflowed comments
+Daniel Stenberg (25 May 2017)
+- [Thomas Köckerbauer brought this change]
 
-Guenter Knauf (11 Jul 2012)
-- Cleaned up version awk script.
+  configure: do not heck for ar if specified manually
+  
+  Closes #62
 
-Daniel Stenberg (30 Jun 2012)
-- [Gisle Vanem brought this change]
+David Drysdale (23 May 2017)
+- ares_expand_name: limit number of indirections
 
-  read_udp_packets: bail out loop on bad sockets
-  
-  I can see that recvfrom() in ares_process.c many times is called with
-  'udp_socket' == ARES_SOCKET_BAD. The code takes care not to call
-  recv/recvfrom with ARES_SOCKET_BAD in the outer-loop. So should the
-  inner-loop.
+- test: fuzz input file that takes a while to process
 
-Yang Tse (29 Jun 2012)
-- cares-compilers.m4: remove -Wstrict-aliasing=3 from clang
+- test: copy data in fuzz regression driver
   
-  Currently it is unknown if there is any version of clang that
-  actually supports -Wstrict-aliasing. What is known is that there
-  are several that don't support it.
+  Oops.
 
-- cares-compilers.m4: -Wstrict-aliasing=3 for warning enabled gcc and clang builds
+GitHub (23 May 2017)
+- [David Drysdale brought this change]
 
-Daniel Stenberg (18 Jun 2012)
-- version: work towards 1.9.2 (at least)
+  Convert char from ISO-8859-1 to UTF-8 (#99)
+  
+  Fixes #97
 
-Version 1.9.1 (18 Jun 2012)
+- [Gregor Jasny brought this change]
 
-Daniel Stenberg (18 Jun 2012)
-- RELEASE-NOTES: 1.9.1 coming up
+  travis: Use trusty for cmake builds (#109)
+  
+  kubuntu-backports dropped the CMake package for Precise
 
-Version 1.9.0 (16 Jun 2012)
+David Drysdale (2 May 2017)
+- [David Hotham brought this change]
 
-Daniel Stenberg (16 Jun 2012)
-- ares_version.h: next version is 1.9.0
+  msvc_ver.inc support most recent Visual Studio 2017 (#101)
 
-- [Marko Kreen brought this change]
+- test: use io.h not unistd.h for Windows
 
-  ares_data.h: ARES_DATATYPE_SOA_REPLY is added in 1.9.0
+- test: try building fuzz binaries on Windows
 
-- RELEASE-NOTES: synced with 979bf951d
+- test: stick to int in ares-fuzz.c
   
-  Next release deemed to become 1.9.0 due to the new function
+  Using int rather than ares_ssize_t means this file
+  needs no c-ares dependency - it's a general driver for
+  any libFuzzer-style entrypoint.
 
-- [Marko Kreen brought this change]
+- test: force ARES_OPT_NOROTATE for no-rotate tests
 
-  SOA parser added
-  
-  I need to do SOA queries, so here is a parser for them.
+- test: check expected NOROTATE value
+
+- ares_create_query: use ares_free not naked free
   
-  - ares_soa_reply: new struct
-  - ares_malloc_data/ares_free_soa: ARES_DATATYPE_SOA_REPLY
-  - ares_parse_soa_reply: actual function
+  Accidentally added in commit 65c71be1cbe5
+  ("ares_create_query: avoid single-byte buffer overwrite")
 
-Yang Tse (14 Jun 2012)
-- Kill compiler warning
+Brad House (17 Mar 2017)
+- Need ares.h for ares_ssize_t
 
-- Fix libcares.pc generation for static MingW* cross builds
+- tests should not use ssize_t, use ares_ssize_t
 
-Daniel Stenberg (21 May 2012)
-- [Nick Alcock brought this change]
+GitHub (16 Mar 2017)
+- [Brad House brought this change]
 
-  Fix UDP and TCP port byte order in saved options.
+  Portability updates for legacy systems. (#92)
   
-  The UDP and TCP port are stored in network byte order in the
-  ares_channeldata, but are passed in to ares_init_options() in host byte
-  order.  Thus we must return them from ares_save_options() in host byte
-  order too, or a duplicated channel will convert them again, leading to a
-  nonfunctional channel and a mysterious connection refused error from
-  ares_gethostbyname().  This breaks ares_dup(), thus the curl easy API
-  when c-ares is used by curl, and thus all the curl easy API's users.
+  Socklen_t should not be used in code, instead ares_socklen_t should be used.
+  Convert ssize_t to ares_ssize_t for portability since the public API now exposes this.
 
-Yang Tse (28 Apr 2012)
-- version: start working on 1.8.1-DEV
-
-Version 1.8.0 (27 Apr 2012)
+David Drysdale (14 Mar 2017)
+- [Michael Osei brought this change]
 
-Daniel Stenberg (27 Apr 2012)
-- RELEASE-NOTES: call next 1.8 instead
+  Update msvc_ver.inc (#91)
   
-  Since we added a function, let's use a stricter bumping scheme
+  For Visual Studio 2017 builds
 
-Yang Tse (25 Apr 2012)
-- INSTALL: some adjustments
+Daniel Stenberg (13 Mar 2017)
+- [Brad House brought this change]
 
-Daniel Stenberg (25 Apr 2012)
-- GIT-INFO: mention buildconf
+  Windows DNS server sorting (#81)
+  
+  Original Patch From Brad Spencer:
+  https://c-ares.haxx.se/mail/c-ares-archive-2016-04/0000.shtml
+  
+  My modifications include:
+   * Dynamically find GetBestRoute2 since it is a Windows Vista+ symbol, and will fall back to prior behavior when not available.
+   * Prefer get_DNS_AdaptersAddresses as the modifications should alleviate the concerns which caused us to prefer get_DNS_NetworkParams
+   * Update AppVeyor to use MinGW-w64 instead of the legacy MinGW
+   * Fix compile error in test suite for Windows.
+  
+  Original message from patch below:
+  
+  From: Brad Spencer <bspencer@blackberry.com>
+  Date: Fri, 29 Apr 2016 14:26:23 -0300
+  
+  On Windows, the c-ares DNS resolver tries first to get a full list of
+  DNS server addresses by enumerating the system's IPv4/v6 interfaces and
+  then getting the per-interface DNS server lists from those interfaces
+  and joining them together. The OS, at least in the way the c-ares
+  prefers to query them (which also may be the only or best way in some
+  environments), does not provide a unified list of DNS servers ordered
+  according to "current network conditions". Currently, c-ares will then
+  try to use them in whatever order the nested enumeration produces, which
+  may result in DNS requests being sent to servers on one interface
+  (hosting the current default route, for example) that are only intended
+  to be used via another interface (intended to be used when the first
+  interface is not available, for example). This, in turn, can lead to
+  spurious failures and timeouts simply because of the server address
+  order that resulted because of the enumeration process.
+  
+  This patch makes the (safe?) assumption that there is no other better
+  rule to chose which interface's DNS server list should be prioritized.
+  After all, a DNS lookup isn't something "per network"; applications
+  don't look up "these DNS names on this interface and those DNS names on
+  that interface". There is a single resource pool of DNS servers and the
+  application should presume that any server will give it the "right"
+  answer. However, even if all DNS servers are assumed to give equally
+  useful responses, it is reasonable to expect that some DNS servers will
+  not accept requests on all interfaces. This patch avoids the problem by
+  sorting the DNS server addresses using the Windows IPv4/v6 routing tables.
+  
+  For example, a request to DNS server C on interface 2 that is actually
+  sent over interface 1 (which may happen to have the default route) may
+  be rejected by or not delivered to DNS server C. So, better to use DNS
+  servers A and B associated with interface 1, at least as a first try.
+  
+  By using the metric of the route to the DNS server itself as a proxy for
+  priority of the DNS server in the list, this patch is able to adapt
+  dynamically to changes in the interface list, the DNS server lists per
+  interface, which interfaces are active, the routing table, and so on,
+  while always picking a good "best" DNS server first.
+  
+  In cases where any DNS server on any interface will do, this patch still
+  seems useful because it will prioritize a lower-metric route's (and thus
+  interface's) servers.
 
-Yang Tse (25 Apr 2012)
-- INSTALL: remove more sections that don't apply to c-ares
+David Drysdale (22 Feb 2017)
+- [Sergii Pylypenko brought this change]
 
-- ares_timeout.c: fix compiler warning
+  docs: fixed references to ares_set_local_ip4 and ares_set_local_ip6
 
-Daniel Stenberg (25 Apr 2012)
-- [Ben Noordhuis brought this change]
+- [Calle Wilund brought this change]
 
-  Makefile.m32: fix mingw32 build
+  ares test: fix win32 build errors with virtual socket function tests
   
-  * add . to include path so ares_build.h is picked up
-  * make ar configurable to ease cross-compiling
+  The added api requires both some typedefs not previously imported
+  into the test build + the test code did not fully deal with
+  socket differences on windows.
 
-- RELEASE-NOTES: added what's happened since 1.7.5
+- [Calle Wilund brought this change]
 
-Guenter Knauf (22 Apr 2012)
-- Updated copyright year.
+  ares_process: fix return type of socket_create function (win32 warning)
 
-Yang Tse (21 Apr 2012)
-- ares_init.c: Further refactoring of Windows system's DNS fetching code
+Daniel Stenberg (31 Jan 2017)
+- [Calle Wilund brought this change]
 
-Guenter Knauf (20 Apr 2012)
-- Android: small changes to dns property part.
+  ares_set_socket_functions: Add man page
   
-  Prefix prop vars; kill var; use DNS_PROP_NAME_PREFIX macro.
-
-- Handle CNAME-only in ares_parse_aaaa_reply().
+  Providing some rudimentary documentation for the added functionality
   
-  posted to the c-ares list by Peter Griess <pg@std.in>.
+  Closes #72
 
-- Add support for multiple DNS servers on Android.
-  
-  Before, c-ares always used the first DNS server on Android, causing
-  network problems if this DNS server was not available.
+- [Calle Wilund brought this change]
+
+  ares-test: Add test helpers and cases for virtual socket IO
   
-  Signed-off-by: Geert Uytterhoeven <Geert.Uytterhoeven@sonycom.com>
+  * Added test case macro to automatically run tests twice, once "normal",
+    once with virtual IO.
+  * Changed most "live" query tests to run in dual mode to verify
+    at least simple socket IO via virtual functions
+  * Added test case for settings/duping socket functions & callback data
 
-- Added INSTALL so it gets into tarballs.
+- [elcallio brought this change]
 
-- Added some more ifdefs to silent compiler warnings.
+  Implement using virtual socket IO functions when set
+  
+  Uses virtual socket IO functions when set on a channel.
+  Note that no socket options are set, nor is any binding
+  done by the library in this case, since the client defining
+  these is probably more suited to deal with this.
 
-Yang Tse (17 Apr 2012)
-- INSTALL: remove a non c-ares section
+- [elcallio brought this change]
 
-- cares-compilers.m4: -Wno-pedantic-ms-format for Windows gcc 4.5 builds
+  Add virtual function set for socket IO
   
-  When building a Windows target with gcc 4.5 or newer and strict compiler
-  warnings enabled use -Wno-pedantic-ms-format in addition to other flags.
+  Defines a structure of basic create, close, read/write
+  functions as virtual function calls, settable for individual
+  c-ares channels.
 
-- setup_once.h: tighten requirements for stdbool.h header inclusion
-  
-  Include stdbool.h only when it is available and configure is capable of
-  detecting a proper 'bool' data type when the header is included.
+David Drysdale (30 Jan 2017)
+- test: ignore aresfuzzname binary
 
-- configure: NATIVE_WINDOWS no longer defined in config file
+Gregor Jasny (14 Jan 2017)
+- [Stephen Sorley brought this change]
 
-- cares-compilers.m4: double underscore decoration for visibility attribute
+  Always use check_symbol_exists instead of check_function_exists.
 
-- build adjustments: CARES_SYMBOL_HIDING no longer defined in config files
-  
-  configure script now provides conditional definitions for Makefile.am
-  that result in CARES_SYMBOL_HIDING being defined by resulting makefiles
-  when appropriate.
+- Also add includes to TARGETS_INST_DEST
 
-- configure: Windows cross-compilation fixes
-  
-  CARES_BUILDING_LIBRARY and CARES_STATICLIB no longer defined in ares_config.h,
-  configure will generate appropriate conditionals so that mentioned symbols
-  get defined and used in Makefile derived from Makefile.am at compilation time.
+- [Stephen Sorley brought this change]
 
-Guenter Knauf (17 Apr 2012)
-- Added INSTALL file adapted from libcurl.
-  
-  Not yet ready, and needs further edits.
+  Windows build fixes
 
-Yang Tse (16 Apr 2012)
-- ares_init.c: get_iphlpapi_dns_info() refactoring
+- CMake: Export targets
 
-Guenter Knauf (16 Apr 2012)
-- Kill some more compiler warnings.
+- CMake: Use GNUInstallDirs for install location defaults
 
-- Kill compiler warning about unused var.
+David Drysdale (11 Jan 2017)
+- Update Makefile.am for renamed INSTALL.md
 
-- Fixed my last commit: wrong preprocessor directive.
+GitHub (11 Jan 2017)
+- [David Drysdale brought this change]
 
-- Check for __ANDROID__ in addition to ANDROID macro.
+  docs: convert INSTALL to MarkDown & tweak (#83)
 
-- Check for __ANDROID__ in addition to ANDROID macro.
-  
-  Posted to c-ares list by Wayne.
+- [Gregor Jasny brought this change]
 
-- Fix for Android to disable useless arpa/nameser.h.
+  Merge pull request #77 from stephen-sorley/cmake_modernize
+  
+  Updated CMake minimum version to 2.8.12.
 
-- Fix for Android to include sys/select.h for fd_set.
+Stephen Sorley (4 Jan 2017)
+- Changed executables to depend directly on internal libcares target, instead of against
+  the external-facing alias targets.
 
-Yang Tse (17 Mar 2012)
-- ares_data.c: some NAPTR related fixes
+- Updated Travis to pull CMake 2.8.12 from kubuntu-backports ppa.
 
-Daniel Stenberg (16 Mar 2012)
-- port numbers: convert them to network order!
+- Updated CMake minimum version to 2.8.12.
   
-  When the config options ARES_OPT_UDP_PORT or ARES_OPT_TCP_PORT are used,
-  make sure to convert them to network byte order!
+  Changed the way usage requirements (include dirs, compile defs, dependent libraries) are specified, to match the recommended standard practice for modern CMake. This involves using target-specific functions (target_include_directories, target_compile_definitions, etc.), along with the PUBLIC, PRIVATE or INTERFACE modifiers.
   
-  Bug: http://c-ares.haxx.se/mail/c-ares-archive-2012-02/0004.shtml
+  Updated chain-building support to imitate new-style Find modules (import libs), instead of old-style Find modules (cache variables).
 
-- white space cleanup
+David Drysdale (26 Dec 2016)
+- [Chris Araman brought this change]
+
+  configure: clock_gettime workaround (#75)
   
-  - Keep code within 80 columns
+  Commits 7518c26, c41726b, and bc14ee7 brought this workaround to the CMake build system. This expands it to the autoconf build system.
   
-  - Removed funny spaces after open paren and before closing paren
+  Fixes #71
 
-- [Poul Thomas Lomholt brought this change]
+- test: add fuzz entrypoint for ares_create_query()
 
-  get_iphlpapi_dns_info: fix buffer overrun
+- test: Add gTest/gMock files to SOURCES
   
-  I experienced a buffer overrun exception in c-ares on Windows and
-  tracked it down to be an error in the calculation of the 'left' variable
-  in get_iphlpapi_dns_info().
+  Built tarballs are not including all of the files needed
+  to build the test suite because they are missing from the
+  <target>_SOURCES variable in Makefile.am.
+
+- travis: Move build scripts under travis/
   
-  I changed the variable type of 'left' to a _signed_ type because of the
-  subtraction arithmetic; not sure if a long is the best choice
+  Travis doesn't always propagate errors in inline multi-line
+  scripts, so move them all to be explicit shell scripts, each
+  with set -e.
 
-- Merge pull request #7 from saghul/naptr
+- travis: check distributed tarball builds
+
+Daniel Stenberg (25 Oct 2016)
+- dist: ship msvc_ver.inc too
   
-  Added support for parsing NAPTR records
+  Reported-by: Bruce Stephens
+  
+  Fixes #69
 
-saghul (23 Feb 2012)
-- Added support for parsing NAPTR records
+- [Aaron Bieber brought this change]
 
-Yang Tse (19 Jan 2012)
-- ares_init.c: fix compiler warning on winsock builds
+  fix build on OpenBSD
 
-- configure: libtool 1.5 tweaks
+- ares_version.h: bump, working on 1.12.1 now
 
-Daniel Stenberg (19 Dec 2011)
-- ares_timeout.3: fix the NAME section
+GitHub (18 Oct 2016)
+- [Gregor Jasny brought this change]
+
+  Merge pull request #64 from bradh352/master
   
-  It was clearly a copy n' paste error
+  Add CMake build system support to C-Ares.
 
-Yang Tse (27 Sep 2011)
-- [Albert Chin brought this change]
+Brad House (5 Oct 2016)
+- suggested PROJECT_NAME change broke chain building as it needs the magic PROJECT_NAME set in the ADD_LIBRARY for matching. Fix to make both goals work
 
-  configure - m4: make CURL_CHECK_DEF ignore leading whitespace on symbol def
+- update MacOSX 10.12 detection
+
+- Expand XCode clock_gettime fix to include MacOS 10.12, not just iOS10
+
+David Drysdale (4 Oct 2016)
+- Revert "travis: work around bug in PyCParser"
   
-  When using Sun C compiler the preprocessor somehow inserts an extra space
-  in front of replaced symbol, breaking CURL_CHECK_DEF macro. To workaround
-  this, macro CURL_CHECK_DEF now ignores all leading whitespace in front of
-  symbol substitution result.
+  This reverts commit a24a10a348fc00b8cfd684d91894a1df14880ea9.
 
-- ares_init.c: fix segfault triggered in ares_init_options() upon previous
-               failure of init_by_defaults() and incomplete cleanup there.
+- travis: work around bug in PyCParser
+  
+  See https://github.com/pyca/cryptography/issues/3187
 
-- ares_process.c: fix compiler warning
+Brad House (3 Oct 2016)
+- PROJECT_SOURCE_DIR instead of CMAKE_CURRENT_SOURCE_DIR as per @gjasny
 
-- fix MSVC compiler warning 'conditional expression is constant'
+- use a project name of c-ares as per @gjasny
 
-- setup_once.h cleanup and sync
+- Import curl conversion of Makefile.inc to cmake form dynamically as per bdoetsch@ameritech.net to make maintaining multiple build systems easier
 
-- [Denis Bilenko brought this change]
+Daniel Stenberg (30 Sep 2016)
+- dist: add ares_library_initialized.* to the tarball
 
-  ares_getnameinfo: fix random results with c-ares 1.7.5
-  
-  In ares_getnameinfo memcpy did not copy enough bytes, causing
-  it to return arbitrary memory contents as a result.
+David Drysdale (30 Sep 2016)
+- test: check ares_create_query with too-long name
 
-- warnings: fix another 'conversion may lose significant bits' compiler warning
+Daniel Stenberg (30 Sep 2016)
+- man pages: minor formatting edits
 
-- ares_dns.h: adjust DNS__16BIT and DNS__32BIT macro definitions
-  
-  Fixing compiler warnings existing definitions triggered on these.
+Brad House (29 Sep 2016)
+- merge fc7917e from @daviddrysdale ... travis build updates for cmake
 
-- ares_destroy.c: fix segfault in ares_destroy_options()
+- cleanups as per @gjasny ... Use naked IF statements and use NOT DEFINED
 
-Daniel Stenberg (21 Aug 2011)
-- ares_parse_srv_reply: silence compiler warnings
-  
-  ... by adding ugly typecasts.
+Version 1.12.0 (29 Sep 2016)
 
-- CHANGES: generate from script
-  
-  The CHANGES file is now generated automatically with 'git2changes.pl',
-  invoked by the maketgz script which is used to build release archives.
-  
-  The former human edited CHANGES file was renamed to CHANGES.0 in git.
+Daniel Stenberg (29 Sep 2016)
+- RELEASE-NOTES: 1.12.0
 
-Yang Tse (21 Aug 2011)
-- Makefile.netware: SIZEOF_SHORT definition
+- [David Drysdale brought this change]
 
-- warnings: fix some 'conversion may lose significant bits' compiler warnings
+  ares-test-misc: test ares_create_query with escaped trailing dot
 
-- configure: fix symbol hiding usability check
+- ares_create_query: avoid single-byte buffer overwrite
   
-  A more thorough test is done now in order to determine visibility attribute
-  usability, given that some compilers don't support visibility attribute on
-  all configurations.
+  ... when the name ends with an escaped dot.
+  
+  CVE-2016-5180
+  
+  Bug: https://c-ares.haxx.se/adv_20160929.html
 
-Daniel Stenberg (16 Aug 2011)
-- 1.7.6: start working...
+Brad House (29 Sep 2016)
+- CMake: Unify library versioning with the libtool methodology to make keeping library versions in sync easier with the autotools build system
 
-Version 1.7.5 (16 Aug 2011)
+Daniel Stenberg (29 Sep 2016)
+- ares_library_initialized.3: added
 
-Daniel Stenberg (16 Aug 2011)
-- CHANGES: synced for 1.7.5 release
+- make: bump CARES_VERSION_INFO for release
 
-- RELEASE-NOTES: synced with bb4096effef7f000
+David Drysdale (29 Sep 2016)
+- man: update ares_init_options.3
 
-Jakub Hrozek (15 Aug 2011)
-- Only fall back to AF_INET searches when looking for AF_UNSPEC addresses
+Daniel Stenberg (29 Sep 2016)
+- ares_library_init.3: corrected the ares_library_init_mem proto
 
-Yang Tse (10 Aug 2011)
-- [Gisle Vanem brought this change]
+Brad House (28 Sep 2016)
+- XCode v8 introduced clock_gettime() for iOS v10.  However, it is a weak symbol, which means when earlier iOS versions try to use clock_gettime() it results in a crash due to the missing symbol.  Detect this condition and do not set HAVE_CLOCK_GETTIME_MONOTONIC.
 
-  ares_iphlpapi.h: Watcom C fix
+- Adds cmake build system support to C-Ares.
   
-    Added "!defined(_WS2DEF_)" since Watcom doesn't have
-    a per type guard for the typedefs 'CSADDR_INFO' (that MingW has) or
-    'SOCKET_ADDRESS' (that MSVC has). But we can use the header-guard for
-    <ws2def.h> instead.
-
-- [Gisle Vanem brought this change]
+  The patch does not modify any source files, it only adds 3 new files
+  (CMakelists.txt, ares_build.h.cmake, ares_config.h.cmake) which form the
+  build system.  I've tried to go through as much of the autotools tests and
+  extracted what I thought was appropriate, though many of the tests aren't
+  as in-depth in CMake as they are for autotools ... it is unclear why some
+  of them exist at all, I'm guessing for legacy systems that CMake probably
+  doesn't support anyhow.
+  
+  Building the library, and examples (adig, ahost, acountry) plus installation
+  should work across a large number of tested platforms.  The tests have not
+  yet been integrated.
 
-  Makefile.Watcom:
-    * The 'NTDDI_VERSION' needs to be raised to 0x05010000
-      in order for SOCKADDR_STORAGE etc. to be typedefed.
-    * Replaced '-dUSE_WATT32' with '-dWATT32'.
-    * Added $(DEMOS) to the 'all' target and removed the 'demos'
-      target to be consistent with e.g. Makefile.msvc etc.
-    * 'ENABLE_IPV6' is no longer used. Hence removed the '%use_ipv6' construct.
-    * object-file order seems to be important (Watcom v.19). Hence
-      'ares_getopt.obj' must be put after the .obj that references getopt().
+Daniel Stenberg (27 Sep 2016)
+- README.md: remove space from link
 
-- cares-compilers.m4: CARES_CONVERT_INCLUDE_TO_ISYSTEM adjustments
-  
-  Add CARES_CHECK_COMPILER as a requirement.
+- README: link to the correct c-ares badge!
   
-  Ensure macro does nothing unless GNU_C or CLANG compiler is used.
+  Reported-by: David Hotham
   
-  This should allow usage of this macro in unforeseen placements.
+  Fixes #63
 
-- config-win32.h: comments adjustments - followup
+- docs: minor formatting edits
 
-- config-win32.h: comments adjustments
+- ares_destroy.3: formatting polish
 
-Daniel Stenberg (5 Aug 2011)
-- [Tom Hughes brought this change]
+- ares_init.3: split the init docs into two separate man pages
 
-  ares_parse_a_reply: fix memleak
+- SECURITY: point to the vulnerabilities page now
 
-Yang Tse (29 Jul 2011)
-- cares-functions.m4 serial # bump
+- RELEASE-NOTES: synced with daa7235b1a5
 
-- Revert "configure: additional flag checks for fcntl() and socket()"
+- ares_create_query.3: edit language
   
-  This reverts commit 5f2a3b0e48f26d24cb1fefea0dccb92d417dcbf7.
-
-- configure: additional flag checks for fcntl() and socket()
+  Tried to make the man page more readable.
 
-- xc-translit.m4 fix quoting
+David Drysdale (26 Sep 2016)
+- test: fix gMock to work with gcc >= 6.x
+  
+  Taken from:
+  https://github.com/google/googletest/issues/705#issuecomment-235067917
 
-- configure: avoid direct usage of AS_TR_* macros
+Daniel Stenberg (26 Sep 2016)
+- [Brad House brought this change]
 
-- xc-translit.m4 provides transliteration macros with well defined behavior.
+  headers: remove checks for and defines of variable sizes
+  
+  ... they're not really used and by avoiding them in the ares_build.h
+  output we make the public header less dependent on data sizes.
 
-Jakub Hrozek (15 Jun 2011)
-- Revert "Only fall back to AF_INET searches when looking for AF_UNSPEC addresses"
+David Drysdale (24 Sep 2016)
+- api: add ARES_OPT_NOROTATE optmask value
   
-  This reverts commit b5823d65706af687c0e5110af8f0cfdcd068997d.
+  Fix up a couple of problems with configuring whether c-ares rotates
+  between different name servers between requests.
   
-  This patch was not reviewed properly before pushing
-
-- Revert "Do not use sized constants in public headers"
+  Firstly, ares_save_options() returns (in *optmask) the value of
+  (channel->optmask & ARES_OPT_ROTATE), which doesn't necessarily
+  indicate whether the channel is or is not actually doing rotation.
+  This can be confusing/incorrect if:
+   - the channel was originally configured without ARES_OPT_ROTATE
+     (so it appears that the channel is not rotating)
+   - the /etc/resolv.conf file includes the 'rotate' option
+     (so the channel is actually performing rotation).
   
-  This reverts commit 22c01e96f7b2ae9923e1baa50bfe3c0d22297a7d.
+  Secondly, it is not possible to reliably configure a channel
+  to not-rotate; leaving off ARES_OPT_ROTATE is not enough, since
+  a 'rotate' option in /etc/resolv.conf will turn it on again.
   
-  This is a Red Hat specific patch that does not belong into upstream
-
-- Use correct sizeof in ares_getnameinfo()
-
-- Do not leak rr_name on failures inside ares_parse_ptr_reply
-
-- Do not leak rr_name on failures inside ares_parse_a_reply
-
-- Do not leak rr_name on failures inside ares_parse_aaaa_reply
-
-- Do not leak rr_name on failures inside ares_parse_ns_reply
-
-- Fix incorrect sizeof() in ares_save_options
+  Therefore:
+   - add an ARES_OPT_NOROTATE optmask value to allow explicit
+     configuration of no-rotate behaviour
+   - in ares_save_options(), report the value of channel->rotate
+     as exactly one of (optmask & ARES_OPT_ROTATE) or
+     (optmask & ARES_OPT_NOROTATE).
+  
+  In terms of back-compatibility:
+   - existing apps that set ARES_OPT_ROTATE will continue to rotate,
+     and to have ARES_OPT_ROTATE reported back from ares_save_options()
+   - existing apps that don't set ARES_OPT_ROTATE will continue to
+     use local config/defaults to decide whether to rotate, and will
+     now get ARES_OPT_ROTATE or ARES_OPT_NOROTATE reported back from
+     ares_save_options() rather than 0.
 
-- Fix incorrect allocation in ares_parse_ptr_reply()
+- ares_init_options: only propagate init failures from options
+  
+  Commit 46bb820be3a8 ("ares_init_options: don't lose init failure")
+  changed init behaviour so that earlier errors in initialization
+  weren't lost.  In particular, if the user passes in specific
+  options but they are not applied (e.g. because of an allocation
+  failure), that failure needs to be reported back to the user; this
+  also applies when duplicating a channel with ares_dup().
+  
+  However, other initialization failures can be ignored and
+  overridden -- in particular, if init_by_resolv_conf() or
+  init_by_environment() fail, then falling back to default values
+  is OK.
+  
+  So only preserve failures from the init_by_options() stage, not
+  from all initialization stages.
+  
+  Fixes issue 60.
 
-- Only fall back to AF_INET searches when looking for AF_UNSPEC addresses
+- test: Force reinstall of libtool on OSX
+  
+  Travis build environment appears to have changed.
 
-- Do not use sized constants in public headers
+- test: Add valgrind build variant
 
-Daniel Stenberg (13 Jun 2011)
-- [Jakub Hrozek brought this change]
+- test: Add null pointer to gtest args
+  
+  GoogleTest assumes that there is a null pointer in argv[argc],
+  so make it look like that. Without this change, tests run with
+  command-line arguments get memory errors under valgrind/ASAN.
 
-  ares_free_hostent(NULL) should be a noop
+Daniel Stenberg (21 Aug 2016)
+- AUTHOR: maybe gitgub isn't really an author =)
 
-Yang Tse (8 Jun 2011)
-- configure: fix recvfrom 5th arg type qualifier detection (followup)
+- AUTHORS: added contributors from the git log
 
-- configure: fix recvfrom 5th arg type qualifier detection
+- LICENSE.md: add a stand-alone license file
   
-  Additionally remove whitespace from EOL
+  Just the MIT license used in the top the source files moved out to a
+  stand-alone file for easier reference and discovery.
 
-Daniel Stenberg (4 Jun 2011)
-- strlen: use size_t to receive the return
+- README: added "CII best practices" badge
 
-Yang Tse (4 Jun 2011)
-- xlc: avoid preprocessor definition usage when linking
+- SECURITY.md: suggested "security process" for the project
 
-- ares_nowarn: icc 9.1 workaround
+David Drysdale (17 Aug 2016)
+- test: Add Clang static analysis build to Travis
+  
+  Run scan-build over the library source code, but skip the
+  tests.  Needs a later Clang install in Travis
 
-- ares_nowarn: header inclusion fix
+- test: more info on how to run fuzz testing
 
-- ares_init: make ares_private.h last included header again
+- test: make fuzzer driver code C not C++
 
-- compiler warning: fix
+- test: fuzzer mode for AFL's persistent mode
   
-  Fix compiler warning: conversion may lose significant bits
+  When fuzzing with AFL, if the LLVM-based instrumentation is
+  used (via the afl-clang-fast wrapper), then it is possible to
+  have a single execution of the fuzzer program iterate multiple
+  times over the fuzzing entrypoint (similar to libFuzzer's normal
+  mode of execution) with different data.  This is much (e.g. 10x)
+  faster.
+  
+  Add code to support this, by checking whether __AFL_LOOP is
+  defined at compile-time.
+  
+  Also, shift the code to effectively be C rather than C++.
 
-- compiler warning: fix
+- test: simplify deps for fuzzer entrypoint
   
-  Fix compiler warning: variable was set but never used
+  No need to depend on the rest of the test code (ares-test.h) for
+  the fuzzer entrypoint; this makes the entrypoint slightly simpler
+  to build with LLVM's libFuzzer.
   
-  Fix compiler warning: clobber ignored
+  Also shift the code to effectively be C rather than C++
 
-- ares_iphlpapi: fix compiler warnings
+- test: disable MinGW tests
+  
+  The test binary built in the MinGW build is failing for some
+  reason.  It works for me when I build locally, so I'm guessing
+  it's down to some sort of AppVeyor environment issue.
+  
+  Disable for now.
 
-- winsock: compilation fixes
+Daniel Stenberg (16 Aug 2016)
+- read_tcp_data: remove superfluous NULL check
   
-  Provide winsock iphlpapi alternative definitions to prevent compilation
-  failures when using a variety of winsock header implementations.
+  CID 56884 by Coverity. The pointer is already derefenced before this
+  point so it can't be NULL here anyway.
 
-Daniel Stenberg (17 May 2011)
-- [David Stuart brought this change]
+- web: http => https
 
-  IPv6-on-windows: find DNS servers correctly
+GitHub (20 Jul 2016)
+- [David Drysdale brought this change]
 
-- man pages: docs for the c-ares utility programs
+  Merge pull request #59 from fuze/master
+  
+  Update msvc_ver.inc for VS2015 Update 3
 
-- ares_parse_ns_reply.c: remove CVSism
+- [Chris Araman brought this change]
 
-Yang Tse (27 Mar 2011)
-- build: fix header inclusion
+  Update msvc_ver.inc
+  
+  support Visual Studio 2015 Update 3
 
-- getservbyport replacement for Win CE
+David Drysdale (2 May 2016)
+- Fix trailing comment for #endif
 
-- renamed getplatform() to ares__getplatform() to avoid namespace pollution
+Daniel Stenberg (30 Apr 2016)
+- email: use Gisle's "new" address
 
-- configure: fix libtool warning
+David Drysdale (18 Apr 2016)
+- test: drop superfluous fuzz inputs
   
-  Recent versions of libtool are now tracing usage of AC_CONFIG_MACRO_DIR
-  macro and warn heavily when not used in configure script along with
-  ACLOCAL_AMFLAGS in Makefile.am.  So in order to make libtool happy
-  while keeping backwards compatibility this is added.
+  Where there are multiple fuzz input files that only differ in
+  the first two bytes (the query ID), just keep the first such
+  file.
 
-- adig: RFC4034 resource record type detection
+svante karlsson (15 Apr 2016)
+- Update msvc_ver.inc
   
-  Can be tested with: adig -s 8.8.8.8 -t ANY example.com
+  support Visual Studio 2015 Update 2
 
-- nameser.h: RFC4034 resource record type definitions
+David Drysdale (31 Mar 2016)
+- test: Run fuzzcheck.sh in Travis build
 
-- build: move platform stuff to ares_platform.c and ares_platform.h
+- test: add fuzzing check script to tests
+  
+  Add a test script that runs the fuzzing command over the
+  corpus of DNS packets.  This doesn't actually do any fuzzing
+  (it just runs them as inputs without generating any variations)
+  but it does ensure that the fuzzing entrypoint is still working.
 
-- build: find out windows platform using GetVersionEx()
+- test: allow multiple files in aresfuzz command line
+  
+  If no arguments are specified, use stdin as input.
+  Otherwise treat each argument as a filename and feed
+  its contents to the fuzz entrypoint.
 
-- build: use getenv() replacement function for systems which lack it
+- test: Add corpus of DNS packets
+  
+  For fuzz testing it is useful to start from a corpus of valid
+  packets, so fill out the test/fuzzinput/ directory with a bunch
+  of inputs.
+  
+  These packets were generated by temporarily modifying the c-ares
+  process_answer() function to save off any incoming response messages.
 
-- setup_once: system error codes for Windows CE
+- test: Add utility to show DNS packet from file
 
-- ares_search: use ERRNO macro for portability sake
+- [nordsturm brought this change]
 
-- System's errno.h inclusion cleanup follow-up.
+  Fix nsort initialization
   
-  System's errno.h is conditionally included from setup_once.h
+  Author: Alexander Drachevskiy
+  http://c-ares.haxx.se/mail/c-ares-archive-2014-07/0004.shtml
+  http://c-ares.haxx.se/mail/c-ares-archive-2014-07/0014.shtml
 
-- Windows CE specific adjustment
-  
-  All versions of Windows CE support Winsock 1.1
+- test: Check setting nsort=0 option is respected
 
-- System's errno.h inclusion cleanup.
+- test: Update fuzzing function prototype
   
-  System's errno.h is conditionally included from setup_once.h
+  libFuzzer changed expected return type from void to int
+  in LLVM 3.8.
 
-- ares_init: fix gethostname error detection on winsock platforms
+- Explicitly clear struct servent before use
+  
+  On a build where MSAN has been manually set up (which involves
+  using an MSAN-instrumented version of the standard C++ library, see
+  https://github.com/google/sanitizers/wiki/MemorySanitizerLibcxxHowTo)
+  there's a warning about use of uninitialized memory here.  It
+  might be a false positive, but the fix is trivial so include it.
 
-- configure: r-enable temporarily disabled detection of system's inet_ntop()
+- test: for AF_UNSPEC, return CNAME only for AAAA, but valid A record
   
-  Detection was temporarily disabled in commit 674e044ccb21f2f63537da53565fce868f
+  Also shuffle expected responses rsp6/rsp4 into the order they will occur.
 
-Daniel Stenberg (15 Mar 2011)
-- configure: stop using the deprecated AM_INIT_AUTOMAKE syntax
+- [Chris Araman brought this change]
 
-- [Gisle Vanem brought this change]
+  msvc_ver.inc: support Visual Studio 2015 Update 1
 
-  Watt-32: use errno
+- build: commonize MSVC version detection
   
-  Make sure Watt-32 programs use 'errno' even on Win32 targets
+  Remove the need to copy/paste version number mapping between
+  Makefile.msvc and test/Makefile.msvc.
 
-Guenter Knauf (18 Feb 2011)
-- Removed commented CLFAGS no longer needed.
+- test: Use different name in live test
 
-- Fixed CFLAGS for NetWare.
-  
-  Added -m32 to enable compilation with x86_64 compilers;
-  added conditional to set -fpcc-struct-return only for gcc compiler.
+- test: Only pass unused args to GoogleTest
 
-Daniel Stenberg (18 Feb 2011)
-- [Gisle Vanem brought this change]
+- ahost.c: add cast to fix C++ compile
+  
+  If ahost.c is force-compiled as C++ the missing cast from
+  (void *) to (char **) is problematic.
 
-  Watt32: fix server init
+- ares_library_cleanup: reset ares_realloc too
   
-  Somewhere in the process, programs using the Watt-32 tcp/ip stack
-  stopped working.
+  Otherwise a subsequent use of the library might use a previous
+  incarnation's realloc() implementation.
 
-- [Dima Tisnek brought this change]
+Daniel Stenberg (9 Mar 2016)
+- [Brad House brought this change]
 
-  config_sortlist: (win32) missing else
+  configure: check if tests can get built before enabled
   
-  Without an else there, contents of "pat" that could have been
-  successfully set just above, may be clobbered by successive unsuccessful
-  calls to "xxx_pton" or "ip_addr".
-
-Yang Tse (17 Jan 2011)
-- Makefile.msvc: add a couple of VS version strings
+  The current approach for disabling tests is not a good solution because
+  it forces you to pass --disable-tests, rather than auto-detect if your
+  system can support the tests in the first place.  Many (most?) systems
+  do not have C++11.  This also causes issues when chain-building c-ares,
+  the hosting system needs to be updated to support passing this
+  additional flag if necessary, it doesn't seem reasonable to add this
+  requirement which breaks compatibility.
+  
+  This change auto-detects if the system can build the tests and
+  automatically disable them if it cannot.  If you pass --enable-tests to
+  configure and the system cannot build them either due to lack of system
+  support, or because cross-compilation is being used, it will throw an
+  appropriate error since the user indicated they really did want the
+  tests.
 
-- Makefile.msvc: add a couple of VS version strings
+David Drysdale (3 Mar 2016)
+- [Viktor Szakats brought this change]
 
-- build: add install target to Makefile.msvc
+  Makefile.m32: add support for CROSSPREFIX
 
-Daniel Stenberg (27 Dec 2010)
-- ares_set_servers_csv: remove unused variables
+- [Viktor Szakats brought this change]
 
-- init_by_resolv_conf: fix compiler warnings
+  Makefile.m32: add support for extra flags
   
-  The code received the return codes in the 'status' variable without
-  using it. Instead we just ignore those particular errors.
+  Allow specification of CARES_{LD,C}FLAG_EXTRAS envvars
+  for mingw
 
-- getv4: Value stored to 'dst' is never read
+- test: Build with MinGW on AppVeyor
 
-- advance_tcp_send_queue: avoid NULL ptr dereference
+- test: avoid in6addr_* constants
   
-  If given a too large 'num_bytes' value, it would cause a NULL ptr
-  dereference. Instead the code will now break out of the loop at the end
-  of the list.
+  These aren't available on MinGW, so use explicit addresses instead.
 
-- [Peter Pentchev brought this change]
+- test: add missing #includes for dns-proto.cc
 
-  configure: fix a bashism
+- [Gregor Jasny brought this change]
 
-- cleanup: avoid unsafe typecasts
-  
-  Avoid the risk of reading 16bit data from an unaligned address by using
-  a macro that is adapted for this.
+  Fix man page typos detected by Lintian
 
-- [Stefan Bühler brought this change]
+Daniel Stenberg (19 Feb 2016)
+- configure: acknowledge --disable-tests
+  
+  Fixes #44
 
-  ares_expand_name: Fix encoded length for indirect root
+- AUTHORS: added contributors from the 1.11.0 release
 
-Yang Tse (18 Dec 2010)
-- build: add some explicit file references to VS project files
+- bump: start working on the next version
 
-- config-win32: provide HAVE_ASSERT_H definition
+Version 1.11.0 (19 Feb 2016)
 
-- build: include ares_nowarn in sample program VS project files
+Daniel Stenberg (19 Feb 2016)
+- RELEASE-NOTES: final edits for 1.11.0
 
-- build: include ares_nowarn among SAMPLESOURCES and SAMPLEHEADERS
+David Drysdale (15 Feb 2016)
+- ares_dup.3: remove mention of nonexistent function
+  
+  ares_dup_options() doesn't exist, so don't document it.
 
-- configure: temporarily disable detection of system's inet_ntop()
+- test: skip repeated build steps
   
-  This is done to allow compilation of ares_inet_ntop() by some daily
-  builds picky compilers that otherwise do not need this function.
+  Top-level buildconf/configure now triggers for the
+  test/ subdir too, so don't need to do explicitly.
 
-- changes: mention last fix
+- test: namespaces unavailable when cross-compiling
 
-- ares_inet_ntop: remove definition and usage of macro SPRINTF
+Daniel Stenberg (13 Feb 2016)
+- configure: only run configure in test when NOT cross-compiling
   
-  Existing definition of SPRINTF always resulted in sprintf() being used,
-  and sprintf() returning 'int' is already used throughout the library.
+  ... as the tests won't run cross-compiled anyway
 
-- ares_inet_ntop: reapply changes from previous c-ares version (III)
+David Drysdale (13 Feb 2016)
+- test: prefer ON_CALL to EXPECT_CALL to reduce flakes
   
-  - Replace 'u_char' with 'unsigned char'.
-  - Replace 'u_int' with 'unsigned int'.
-  - use macros ERRNO and SET_ERRNO() for errno handling.
-
-- ares_inet_ntop: reapply changes from previous c-ares version (II)
-  
-  - Remove rcsid.
-  - Adjust header file inclusions.
-  - ares_inet_ntop used only on systems without a proper inet_ntop function.
-
-- ares_inet_ntop: reapply changes from previous c-ares version (I)
+  For UDP tests, there's a chance of a retry.  EXPECT_CALL only
+  expects a single request to arrive at the server; ON_CALL allows
+  for a UDP retry and repeats the same answer.
   
-  - Replace tabs with spaces.
-  - Use ANSI C style for function declarations and definitions.
-  - Use sizeof with parentheses.
+  Note that ON_CALL and EXPECT_CALL can't be mixed in the same
+  test, and that tests that have a varied sequence of responses
+  for the same repeated request still have to use EXPECT_CALL.
 
-- ares_inet_ntop: fix off by one error triggering out of bounds write
-  
-  ares_inet_ntop would trigger an out of bounds write when the representation
-  of the address required 15 characters, due to not taking in account null
-  termination character.
+Daniel Stenberg (13 Feb 2016)
+- configure: run configure in 'test' too
   
-  Full import of inet_ntop.c from bind-9.5.3rc1 to pull additional fixes.
-
-- ares_nowarn: add conditional inclusion of assert.h header
+  Having the test dir completely stand-alone causes too many issues for
+  users and devs. It still needs to be built specifically.
 
-- fix compiler warning: conversion may lose significant bits
+- configure: build silently by default
 
-- ares_inet_net_pton: fix non-rejection of some malformed literals
-  
-  ares_inet_net_pton would return wrong values when excessively large,
-  and invalid, netmasks are used. Fixes are from bind-9.5.3rc1,
-  issue also described in the WLB-2008080064 advisory.
+- buildconf: run test/buildconf too if present
 
-- setup_once: provide ISASCII macro
+- test/configure: build silently by default
 
-- configure: inet_net_pton function check adjustments
-  
-  Define HAVE_INET_NET_PTON only when system's inet_net_pton function is IPv6
-  capable and is not affected by the WLB-2008080064 advisory.
-  
-  HAVE_INET_NET_PTON_IPV6 is no longer defined nor used.
+- [Gregor Jasny brought this change]
 
-- ares_init: fix detection of semicolon comments in resolv.conf
+  dist: Distribute README.md
   
-  File resolv.conf may either use a hash '#' or a semicolon ';' character as an
-  indication that the rest of the line is a comment.  This fixes not recognizing
-  the semicolon as a valid comment indicator in resolv.conf.
-
-- version: start working on 1.7.5
+  Closes #42
 
-Version 1.7.4 (8 Dec 2010)
+Version 1.11.0 (11 Feb 2016)
 
-Daniel Stenberg (8 Dec 2010)
-- release-preps: CHANGES and RELEASE-NOTES synced
+Daniel Stenberg (11 Feb 2016)
+- Makefile.am: distribute the test dir too
 
-- ares_set_local_*: added in 1.7.4, not before
+- RELEASE-NOTES: synced with 385582bd14b68a
 
-Yang Tse (3 Dec 2010)
-- build: provide SIZEOF_SIZE_T definition for non-configure builds
+- [Nicolas \"Pixel\" Noble brought this change]
 
-- build: config.dos renamed to config-dos.h
+  ares_win32_init: make LoadLibrary work when using UNICODE too
+  
+  Closes #17
 
-- build: provide SIZEOF_SIZE_T netware definition
+David Drysdale (11 Feb 2016)
+- Use "resolve" as synonym of "dns" in nsswitch.conf
+  
+  Modern Linux systems may have libnss_resolve from systemd as the
+  resolver, which is then configured in /etc/nsswitch.conf with
+  the "resolve" keyword rather than "dns".
+  
+  Fixes #33
 
-- ares_gethostbyaddr: fix compiler warning: conversion may lose significant bits
+- ares_set_socket_callback: make manpage match code
+  
+  The code in ares_process.c that invokes the socket creation/connection
+  callback only checks for rc < 0, not for standard ares error codes.
 
-- configure: undo using autobuilds to temporarily verify strict aliasing warnings.
+- Merge pull request #36 from AGWA-forks/master
+  
+  Add ares_set_socket_configure_callback()
 
-- fix compiler warning: rounding, sign extension, or loss of accuracy may result
+- test: Update init tests to match behaviour
+  
+  Unreadable config files are now treated the same way
+  as absent config files.
 
-Daniel Stenberg (2 Dec 2010)
-- [Ben Noordhuis brought this change]
+- [Fedor Indutny brought this change]
 
-  ares_parse_a_reply: fix CNAME response parsing
+  Ignore `fopen` errors to use default values
   
-  Reply to a CNAME query doesn't contain addresses, causing
-  ares_parse_a_reply() to bail out with ARES_ENODATA
+  After 46bb820be3a83520e70e6c5f0c5133253fcd69cd `init_by_resolv_conf`
+  errors are no longer swallowed in `ares_init_options`. This has exposed
+  a previously unknown bug in `lookups` initialization code.
   
-  Bug: http://groups.google.com/group/nodejs/browse_thread/thread/a1268c9ea5e9ad9b
+  If there is no lookup configuration in `resolv.conf`,
+  `init_by_resolv_conf` will attempt to read it from other files available
+  on the system. However, some of these files may have restricted
+  permissions (like `600`), which will lead to `EACCESS` errno, which in
+  turn is handled like a fatal error by `init_by_resolv_conf`.
+  
+  However, it sounds illogical that this error should be handled as a
+  fatal. There is a `init_by_defaults` call that overrides `lookups` with
+  default value, and certainly possible absence of lookup information is
+  the reason why this function exists in a first place!
+  
+  I suggest handling any `fopen` errors as non-fatal ones, allowing to
+  pick up the `lookups` value from different config files, or to pick up
+  default value.
 
-Yang Tse (1 Dec 2010)
-- fix compiler warning: conversion may lose significant bits
+Andrew Ayer (9 Feb 2016)
+- Document callback type in man page for ares_set_socket_callback
 
-- atoi: remove atoi usage
+- Add ares_set_socket_configure_callback()
+  
+  This function sets a callback that is invoked after the socket is
+  created, but before the connection is established.  This is an ideal
+  time to customize various socket options.
 
-- ares_init: fix compiler warning: conversion may lose significant bits
+David Drysdale (9 Feb 2016)
+- test: ares_set_socket_callback failure behaviour
 
-- configure: fix autoconf warning
+- test: Check ares_parse_txt_reply_ext() entrypoint
 
-- inet_pton: fix compiler warning
+- [Fedor Indutny brought this change]
 
-- configure: use autobuilds to temporarily verify strict aliasing warnings.
+  txt: introduce `ares_parse_txt_reply_ext`
   
-  Temporarily, When cross-compiling with gcc 3.0 or later, enable strict aliasing
-  rules and warnings. Given that cross-compiled targets autobuilds do not run the
-  test-suite, there is no risk of running code that violates strict aliasing rules
+  Introduce `ares_txt_ext` structure with an extra `record_start`
+  field, which indicates a start of a new TXT record, thus allowing to
+  differentiate the chunks in the same record, from a chunks in a
+  different record.
+  
+  Introduce a new API method: `ares_parse_txt_reply_ext` that works with
+  this kind of struct.
 
-- ares_getnameinfo: Partially revert commit 85520d66e0ac7ac73411bc25e98769a88b2f
+- doc: Update missed repo references
+
+- doc: Update docs on contributing
+
+- test: Run command line tools in Travis
   
-  Upon socket address family and length validation failure return ARES_ENOTIMP
-  in callback again, this is the error code documented in man page and used
-  mostly all over the library.
+  Do a quick execution of each of the command line tools
+  in the continuous integration build, so that any (say)
+  sanitizer failures show up.
 
-- ares_getnameinfo: Validate socket address family and length.
+- acountry: drop inert test
   
-  Validate socket address family and that the socket address length is appropriate
-  for the specified family. Failure is reported with ARES_EBADFAMILY in callback.
+  If ver_1 is true, then z0 and z1 must both be 'z', and so
+  (z0 != 'z' && z1 != 'z') can never be true.
+  
+  CID 56879, pointed out by Coverity.
 
-- ares_getnameinfo: fix two compiler warnings
+- doc: update badge locations to master repo
 
-- Added another VS10 version string
+- test: Enable maintainer mode + debug in Travis
 
-- Fix GCC 4 compiler warning 'dereferencing type-punned pointer might break strict-aliasing rules'.
+- test: Add an iOS build target
 
-- Revert commit 494274e653936335c255a47599970de3df21e7c4
+- test: Ignore SIGPIPE in tests
 
-- configure: fix autoconf 2.68 warning: no AC_LANG_SOURCE call detected in body
+- test: More initialization tests
 
-- Fix compiler warning: array subscript has type 'char'
+- test: Improve containerized test mechanism
+  
+  Aim is to ensure that code coverage information can escape the
+  container.  To do this:
+   - Enter a new mount namespace too, so that we can...
+   - Bind mount the expected source directory into the container
+   - Share memory with the sub-process so coverage information is
+     shared too.
 
-- Fix GCC 4 compiler warning 'dereferencing type-punned pointer might break strict-aliasing rules'.
+- test: Make contained tests easier to write
 
-- Revert following commits:
-    07bc7ea79509bcc9ef6e09151e81766ed00d3392
-    3392a50ea3f8573ea4b7a9d82b9833dab60cb0e9
-    9912637d32c9987719a1ea12db591aee2941891c
+- test: Add framework for containerized testing
   
-  The purpose of the whole patch was to silence a compiler warning triggered
-  with GCC 4 on file ares_process.c  The specific compiler warning was
-  'dereferencing type-punned pointer might break strict-aliasing rules'.
+  On Linux we can potentially use user and UTS namespaces to run  a test
+  in a pseudo-container with:
+   - arbitrary filesystem (e.g. /etc/resolv.conf, /etc/nsswitch.conf, /etc/hosts)
+   - arbitrary hostname/domainname.
   
-  A simpler patch will follow to equally silence the warning.
-
-- ares_options: reorder header inclusions to make inclusion of
-  ares_private.h the last included one again.
+  Include a first pass at the framework code to allow this, along with a
+  first test case that uses the container.
 
-Daniel Stenberg (12 Nov 2010)
-- [Patrik Thunstrom brought this change]
+- test: Use a longer timeout for less flakiness
+  
+  Having occasional test failures from timeout before multiple
+  queries can complete, so up the default timeout for the test
+  from 100ms to 1500ms.
 
-  adig: fix NAPTR parsing
+- test: Make failure tests more robust
   
-  I ran across a small "issue" in your adig example.
+  Different platforms will do different numbers of allocations
+  in the processing of a given API call; just check that the
+  return code is either success or ENOMEM, and free off any
+  returned state in the former case.
   
-  It is simply the last part of the NAPTR record, the replacement element,
-  which is not a string, as currently handled in adig, but a domain name.
-
-- ares_save_options: assignments instead of memcpy
+  Also cope with ECONNREFUSED as well as ENOTFOUND.
 
-- init_by_options: don't copy an empty sortlist
+- test: Get test code building under Windows
   
-  If there aren't any sort items to copy, don't bother. Without this
-  little precaution it would do a malloc(0) which causes undefined
-  behaviors and is frowned upon by curl's memdebug-system.
-
-Guenter Knauf (3 Oct 2010)
-- Minor Watcom makefile tweaks.
+   - Initial nmake file based off library nmake file
+   - Cast socket call arguments to (char *)
+   - Use wrapper sclose() that maps to closesocket() or close()
+   - Build a config.h indicating presence of headers
+   - Conditionally include netdb.h
+   - Remove unnecessary include of sys/socket.h
+   - Force longer bitmask for allocation failure tracking
+   - Call WSAStartup() / WSACleanup() in main()
+   - Set TCP_NODELAY for mock server
+   - Turn on tests in AppVeyor build
 
-Daniel Stenberg (30 Sep 2010)
-- [Mike Crowe brought this change]
+- test: Disable tests that manipulate env on Windows
 
-  Fix lookup with HOSTALIASES set.
-  
-  ares__read_line returns ARES_EOF when it reaches the end of the
-  file. This will happen every time when reading to the end of the
-  HOSTALIASES file. Unfortunately single_domain treats this error as
-  being fatal.
+- test: Move file lists into Makefile.inc
   
-  Signed-off-by: Mike Crowe <mac@mcrowe.com>
+  In preparation for a Win32 build of the test suite.
 
-Ben Greear (24 Aug 2010)
-- Add missing break that caused get_ares_servers to fail.
+- test: Add a simple multi-server test
+  
+  Check rotate option does something
+
+- test: Allow for multiple mock servers
+  
+   - Update the MockServer to allow separate specification of
+     UDP and TCP ports
+   - Have an array of mock servers listening on consecutive
+     sets of ports.
+   - Rename Process(fd) to ProcessFD(fd) to avoid confusion.
+   - Initialize channel by using the new ares_set_servers_ports()
+     entrypoint, so multiple ports on the same loopback address
+     can be used.
+
+- test: Update test for set/get_servers variants
+  
+  Ports are significant in the _ports_ variant functions, so update test to cope.
+
+- test: Make GetNameServers() utility function port-aware
+  
+  Also make it generally available.
+
+- test: more testing, including of internal static functions
+
+- test: more tests, especially fallback processing
+  
+   - Make mock server listen on UDP + TCP in parallel.
+   - Test UDP->TCP fallback on truncation
+   - Test EDNS->no-EDNS fallback
+   - Test some environment init options
+   - Test nonsense reply
+  
+  test: short response
+
+- test: more tests, particularly of initialization
+
+- test: Run mock tests over both TCP and UDP
+  
+  With the exception of a few tests that make use of the timed
+  retry aspect of UDP.
+
+- test: Run mock tests over both IPv4 and IPv6
+
+- test: Add more tests for edge cases
+
+- test: more nooks and crannies of pton functions
+
+- test: More tests for PTR parsing
+
+- test: Use of HOSTALIAS environment variable
+
+- test: Add RAII utility classes for testing
+  
+   - TempFile holds specific contents
+   - EnvValue sets an environment variable
+
+- test: More search domain scenarios
+
+- test: Remove duplicate flags from Makefile.am
+
+- test: Make test code leak-free
+
+- test: More tests
+  
+   - test use of sortlist
+   - test gethostbyname(AF_UNSPEC)
+
+- test: Test ares_gethostbyname_file()
+
+- test: Add more tests of ares_getnameinfo()
+
+- test: Tweak tests, add alloc failure test
+
+- test: Test init with options
+
+- test: More tests
+  
+   - ares_inet_net_pton() variants
+   - ares_getsock() variants
+
+- test: Expose ProcessWork() function
+
+- test: More parsing tests
+  
+  Including:
+   - Split each parse function test set out into separate files.
+   - Add an allocation failure test for each parsing function.
+   - Add error check test for each parsing function.
+
+- test: Add various additional tests
+
+- test: More tests
+  
+  Include tests of internal functions, based on the value of the
+  CARES_SYMBOL_HIDING macro; need to configure the library with
+  --disable-symbol-hiding to enable these tests.
+
+- test: Allow command line override of mock server port
+
+- test: Add README.md documentation
+
+- test: Temporarily avoid latest Python requests package
+  
+  Currently get error from Travis on this install step, and downgrading one
+  version appears to fix the problem.
+  
+  "Could not find any downloads that satisfy the requirement pyOpenSSL>=0.13
+  (from requests[security])"
+
+- test: Add AppVeyor config file for Windows build
+
+- test: Add configuration for a Travis build
+  
+  Cover Linux & OSX on the container infrastructure, but install
+  a later G++ to satisfy the tests' need for C++11.
+  
+  Use a build matrix to include a variety of build variants:
+   - ASAN
+   - UBSAN
+   - LSAN
+   - Coverage via coveralls.io
+  
+  test: invoke ASAN and coverage in Travis build
+  
+  Also shift to use explicit build matrix
+  
+  test: Use coveralls.io for coverage tracking
+  
+  test: Add a build with UBSAN
+  
+  Also expand and re-order the setting of environment variables
+  for easier modification.
+  
+  test: Add LSAN build to Travis config
+
+- test: Add initial unit tests for c-ares library
+  
+  The tests are written in C++11, using the GoogleTest and GoogleMock
+  frameworks.  They have their own independent autoconf setup, so that
+  users of the library need not have a C++ compiler just to get c-ares
+  working (however, the test/configure.ac file does assume the use of
+  a shared top-level m4/ directory).  However, this autoconf setup has
+  only been tested on Linux and OSX so far.
+  
+  Run with "./arestest", or "./arestest -v" to see extra debug info.
+  The GoogleTest options for running specific tests are also
+  available (e.g. "./arestest --gtest_filter=*Live*").
+  
+  The tests are nowhere near complete yet (currently hitting around
+  60% coverage as reported by gcov), but they do include examples
+  of a few different styles of testing:
+  
+   - There are live tests (ares-test-live.cc), which assume that the
+     current machine has a valid DNS setup and connection to the
+     internet; these tests issue queries for real domains but don't
+     particularly check what gets returned.  The tests will fail on
+     an offline machine.
+  
+   - There a few mock tests (ares-test-mock.cc) that set up a fake DNS
+     server and inject its port into the c-ares library configuration.
+     These tests allow specific response messages to be crafted and
+     injected, and so are likely to be used for many more tests in
+     future.
+  
+      - To make this generation/injection easier, the dns-proto.h file
+        includes C++ helper classes for building DNS packets.
+  
+   - Other library entrypoints that don't require network activity
+     (e.g. ares_parse_*_reply) are tested directly.
+  
+   - There are few tests of library-internal functions that are not
+     normally visible to API users (in ares-test-internal.cc).
+  
+   - A couple of the tests use a helper method of the test fixture to
+     inject memory allocation failures, using the earlier change to the
+     library to allow override of malloc/realloc/free.
+  
+   - There is also an entrypoint to allow Clang's libfuzzer to drive
+     the packet parsing code in ares_parse_*_reply, together with a
+     standalone wrapper for it (./aresfuzz) to allow use of afl-fuzz
+     for further fuzz testing.
+
+- test: Add local copy of GoogleMock/GoogleTest 1.7.0
+  
+  Don't check in gtest/m4 files, as they are unused and interfere
+  with the top-level configure process.
+
+- doc: Show build badges in README.md
+  
+  Note that these URLs will need to be updated if/when the test branch
+  gets pulled into the master repo/branch.
+
+- doc: Convert README to README.md
+  
+  Gives better display on GitHub
+
+- doc: Update in preparation for next release
+  
+  Assume 1.11.0 is next (as there are various API additions).
+  Also add myself to AUTHORS.
+
+- build: Allow header compilation by Windows C++ compiler
+
+- build: Expose whether symbol hiding is on
+  
+  Adding the CARES_SYMBOL_HIDING definition allows the test suite to
+  detect whether internal symbols are available or not.
+
+- build: Add autoconf macros for C++11 code using pthreads
+  
+  Pull in testing macros from the GNU autoconf archive to allow
+  configure scripts to test for and setup use of a C++11 compiler
+  (AX_CXX_COMPILE_STDCXX_11) and the pthreads library (AX_PTHREAD).
+  
+  Note that these macros are not used by the main library autoconf,
+  just by the tests (which share the same m4/ directory).
+
+- build: Add a code coverage option
+  
+  Configure with:
+    ./configure --enable-code-coverage
+  Show coverage output with:
+    make code-coverage-capture
+  
+  Built on m4/ax_code_coverage.m4 from the GNU autoconf archive
+  to provide the macros to check for presence of gcov + lcov;
+  upstream macro modified to:
+   - Remove use of $(AM_DEFAULT_VERBOSITY) , as earlier versions of
+     autoconf (such as the one used by default on Travis) do not have this.
+   - Rather than automatically defining CODE_COVERAGE_RULES to be a set
+     of makefile rules that use ifeq/endif (which is GNU make-specific),
+     instead only define CODE_COVERAGE_RULES if coverages is turned on,
+     and in that case don't use conditionals in the makefile.
+
+- api: Add entrypoints to allow use of per-server ports
+  
+  Add user-visible entrypoints ares_{get,set}_servers_ports(3), which
+  take struct ares_addr_port_node rather than struct ares_addr_node.
+  This structure includes a UDP and TCP port number; if this is set
+  to zero, the channel-wide port values are used as before.
+  
+  Similarly, add a new ares_set_servers_ports_csv(3) entrypoint, which
+  is analogous to ares_set_servers(3) except it doesn't ignore any
+  specified port information; instead, any per-server specified port
+  is used as both the UDP and TCP port for that server.
+  
+  The internal struct ares_addr is extended to hold the UDP/TCP ports,
+  stored in network order, with the convention that a value of zero
+  indicates that the channel-wide UDP/TCP port should be used.
+  
+  For the internal implementation of ares_dup(3), shift to use the
+  _ports() version of the get/set functions, so port information is
+  transferred correctly to the new channel.
+  
+  Update manpages, and add missing ares_set_servers_csv to the lists
+  while we're at it
+
+- api: Add ares_set_sortlist(3) entrypoint
+  
+  Allow explicit configuration of the channel's sortlist, by
+  specifying a string in the same format as the equivalent
+  /etc/resolv.conf option.
+  
+  This allows library users to perform the same configuration
+  that is available via /etc/resolv.conf, but without needing
+  to change that file.
+
+- api: Allow injection of user-specified malloc/free functions
+  
+  Add a new ares_library_init_mem() initialization function for the
+  library which allows the library user to specify their own malloc,
+  realloc & free equivalents for use library-wide.
+  
+  Store these function pointers in library-wide global variables,
+  defaulting to libc's malloc(), realloc() and free().
+  
+  Change all calls to malloc, realloc and free to use the function pointer
+  instead.  Also ensure that ares_strdup() is always available
+  (even if the local environment includes strdup(3)), and change the
+  library code to always use it.
+  
+  Convert calls to calloc() to use ares_malloc() + memset
+
+- api: Add option to expose some internal functions
+  
+  Purely for testing, add --enable-expose-statics option to configure
+  which converts some static internal functions to be externally visible.
+
+- api: Expose the ares_library_initialized() function
+
+- ahost: Allow repeated -s <domain> options
+  
+  This also removes a potential leak where later -s options would
+  replace earlier ones without freeing the relevant string.
+
+- Mark unhittable lines
+  
+  Add comments for the benefit of the lcov tool, marking
+  lines that cannot be hit.  Typically these are fall-back
+  protection arms that are already covered by earlier checks,
+  and so it's not worth taking out the unhittable code (in case
+  someone changes the code between the two places in future).
+
+- ares_set_servers_csv.3: make return type match code
+
+- bitncmp: update comment to match code behaviour
+
+- ares_striendstr: fix so non-NULL return can happen
+  
+  This looks to have been broken since it was first introduced in 2005 in
+  commit aba0b775ea30 ("Added ares_getnameinfo which mimics the
+  getnameinfo API")
+
+- config_sortlist: free any existing sortlist on (re)alloc failure
+  
+  If we get an allocation failure on 2nd or later entry in the sortlist, the
+  code would return ENOMEM but still leave the initial entries allocated.
+  Ensure that *sortlist is set to NULL whenever ENOMEM is returned.
+
+- ares_dup: clear new channel on failure
+  
+  If the attempt to transfer IPv6 servers from the old to the new channel
+  fails, the previous code would still return a channel to the user even though
+  an error return code was generated.  This makes it likely that users would
+  leak the channel, so explicitly clear the channel in this case.
+
+- ares_init_options: don't lose init failure
+  
+  If (say) init_by_options() fails, the subsequent call to
+  init_by_defaults() was overwriting the return code with
+  success.  Still call init_by_defaults() regardless, but track
+  its return value separately
+
+- ares_gethostbyname: don't leak valid-but-empty hostent
+  
+  If an AF_UNSPEC query gets a valid response to its AAAA query,
+  but which has no IPv6 addresses in it, then the code chains on to
+  a A record query.  However, the hostent from the AAAA response
+  was being leaked along the way (because it gets replaced before
+  the follow-on end_hquery() invocation).
+
+- ares_parse_txt_reply: propagate errors from per-substring loop
+  
+  If we get an allocation failure when processing a particular substring in a
+  TXT record, that failure is silently lost; fix that by propagating errors from
+  the inner loop to the outer loop.
+
+- process_answer: fix things up correctly when removing EDNS option
+  
+  When a server rejects an EDNS-equipped request, we retry without
+  the EDNS option.  However, in TCP mode, the 2-byte length prefix was
+  being calculated wrong -- it was built from the answer length rather than
+  the length of the original request.
+  
+  Also, it is theoretically possible that the call to realloc() might change
+  the data pointed to; to allow for this, qbuf also needs updating.
+  
+  (Both these fixes were actually included in a patchset sent on the mailing
+  list in Oct 2012, but were included with other functional changes that
+  didn't get merged:
+  http://c-ares.haxx.se/mail/c-ares-archive-2012-10/0004.shtml)
+
+- ares__read_line: clear buf pointer on realloc failure
+
+- ares_expand_name: check for valid bits in label length
+  
+  The top two bits of the label length indicate whether this is a
+  label length (00) or an index to a name elsewhere in the message
+  (11).  RFC1035 4.1.4 says that the other possible values for the
+  top two bits (01, 10) are reserved for future use.
+
+Daniel Stenberg (23 Jan 2016)
+- [Gregor Jasny brought this change]
+
+  Fix typos detected by lintian
+  
+  Closes #32
+
+- [Gregor Jasny brought this change]
+
+  Distribute all man pages
+
+- README.cares: s/I/Daniel
+  
+  ... and add a pointer to an existing version of the original area 1.1.1
+  package.a
+
+- read_tcp_data: don't try to use NULL pointer after malloc failure
+  
+  CID 56884, pointed out by Coverity. We really should make this function
+  return an error code so that a malloc() failure can return back a major
+  failure.
+
+- configure_socket: explicitly ignore return code
+  
+  CID 56889 in Coverity pointed out the return code from setsocknonblock()
+  is ignored, and this added typecast to (void) makes it explicit.
+
+- ahost: check the select() return code
+  
+  Fixes CID 137189, pointed out by Coverity
+
+David Drysdale (18 Jan 2016)
+- Fix buildconf on platforms using glibtoolize
   
-  Reported-by: Ning Dong <flintning@163.com>
-  Signed-off-by: Ben Greear <greearb@candelatech.com>
+  Commit c49a87eea538 changed buildconf to only check for
+  libtoolize, but missed a line
 
-Yang Tse (11 Aug 2010)
-- configure: werror related adjustments
+- Don't exit loop early leaving uninitialized entries
+  
+  Update for commit affc63cba875d.
+  
+  The original patch from Gregor Jasny did not have the break
+  statement; I incorrectly added it to prevent continuing the loop.
+  However, the later entries in the array would then be left
+  uninitialized, causing problems for later cleanup.
+  
+  So fix to match Gregor's original patch, with apologies.
 
-Guenter Knauf (8 Aug 2010)
-- Added copyright string to ares_version.h and make use of it in other files.
+Daniel Stenberg (18 Jan 2016)
+- buildconf: remove check for libtool, it only requires libtoolize
 
-- Block created ares_build.h for NetWare to avoid usage from other platforms.
+David Drysdale (17 Jan 2016)
+- [Gregor Jasny brought this change]
 
-- Fix to overwrite default libname.
+  Use libresolv to initialize cares on iPhone targets
+  
+  On iPhone targets like iOS, watchOS or tvOS the file
+  /etc/resolv.conf cannot be used to configure cares.
+  
+  Instead the resolver library is queried for configuration
+  values.
+  
+  CC: Yury Kirpichev <ykirpichev@yandex-team.ru>
 
-- Some more Watcom makefile massage ...
+Daniel Stenberg (17 Jan 2016)
+- README: updated to new repo URL
 
-- Some more Watcom makefile massage ...
+David Drysdale (14 Jan 2016)
+- [Lei Shi brought this change]
 
-Ben Greear (4 Aug 2010)
-- sock-addr-storage:  Detect and deal with lack of .ss_family member.
+  Fixing slow DNS lookup issue
   
-  AIX, at least, does not have sockaddr_storage.ss_family member.
-  Detect this in the configure logic and use proper #ifdefs in the
-  ares_process logic.
+  This patch is fixing the dns lookup issue due to dummy dns information
+  of a disconnected adapter(in my case is a bluetooth adapter). I changed
+  the dns lookup policy to try GetNetworkParams first because the
+  GetNetworkParams provides the most reliable dns information (lots of
+  checks were done by system). I also filter out inoperable adapter in
+  DNS_AdaptersAddresses in case GetNetworkParams fail.
+
+- Merge pull request #30 from p-push/vs-2015
   
-  Signed-off-by: Ben Greear <greearb@candelatech.com>
-  Tested-by: Tor Arntsen <tor@spacetec.no>
+  Support Visual Studio 2015
 
-Guenter Knauf (3 Aug 2010)
-- Added Watcom makefile based on libcurl's Makefile.Watcom.
+Oleg Pudeyev (3 Jan 2016)
+- [Gisle Vanem brought this change]
 
-Ben Greear (31 Jul 2010)
-- typo:  Fix compile bug for platforms that don't have sockaddr_storage.
+  Support Visual Studio 2015
+
+David Drysdale (11 Nov 2015)
+- [Andrew Andkjar brought this change]
+
+  added another version case to Makefile.msvc
   
-  Bug was introduced by me in previous commit.
+  nmake version 11.00.61030.0 resolves to CC_VERS_NUM = 110
+
+- Merge pull request #26 from bitbouncer/vs-2013
   
-  Signed-off-by: Ben Greear <greearb@candelatech.com>
+  added define for visual studio 2013
 
-- Fix aliasing warning in gcc 4.4.4 (at least).
+svante karlsson (25 Jun 2015)
+- added define for visual studio 2013
+
+Jakub Hrozek (6 Nov 2014)
+- ares__read_line: free buf on realloc failure
+
+- Destroy options if ares_save_options fails
   
-  Should be no functional change, though the code gets a bit
-  ugglier.
+  It's possible that, if ares_save_options failed, the opts structure
+  would contain some allocated memory. Calling ares_destroy_options in
+  this case is safe, because ares_save_options zeroes out the memory
+  initially.
+
+- [David Drysdale brought this change]
+
+  Continue loop if space for hostname not large enough
   
-  Signed-off-by: Ben Greear <greearb@candelatech.com>
+  When attempting to build a search domain from the local hostname
+  (used as a fallback when no other methods have given a search
+  domain), the code doubles the buffer size on each loop iteration.
+  
+  However, the loop previously had a WHILE_FALSE terminator so the continue
+  statement exited the loop rather than going round again.
 
-Daniel Stenberg (31 Jul 2010)
-- ares_set_servers_csv: use ISDIGIT
+Daniel Stenberg (30 Oct 2014)
+- ares_getnameinfo.3: there is no ares_getaddrinfo
+
+David Drysdale (30 Sep 2014)
+- [Gregor Jasny brought this change]
+
+  Prevent tmpbuf from overrunning
   
-  The IS*() set of macros are preferred to the regular is*() functions as
-  they help us avoid the most common pitfalls.
+  Fix Coverity error CID 56886.
+  
+  Signed-off-by: Gregor Jasny <gjasny@googlemail.com>
 
-Ben Greear (30 Jul 2010)
-- cast arg to isdigit to int
+- [Gregor Jasny brought this change]
+
+  Re-start loop if select fails
   
-  Looks like it might silence a warning on Netware build.
+  Fix Coverity error CID 56882
   
-  Signed-off-by: Ben Greear <greearb@candelatech.com>
+  Signed-off-by: Gregor Jasny <gjasny@googlemail.com>
 
-- remove all uses of uint32_t
+- [Gregor Jasny brought this change]
+
+  Free temporary variable in error path
   
-  Previous fix forgot a few.
+  Fix Coverity CID 56890
   
-  Signed-off-by: Ben Greear <greearb@candelatech.com>
+  Signed-off-by: Gregor Jasny <gjasny@googlemail.com>
 
-- fix signed v/s unsigned casts warning in ares_gethostbyaddr.c
+- [Gregor Jasny brought this change]
+
+  Fix integer shift overflow if both tcp_socket and udp_socket are set
   
-  Signed-off-by: Ben Greear <greearb@candelatech.com>
+  The problem occurs if at the start of the loop the sockindex is at the
+  last valid ARES_GETSOCK_MAXNUM position. If then both udp_socket and
+  tcp_socket are valid, sockindex gets incremented for UDP first and
+  points one entry behind the array for the tcp block.
+  So the fix is to check after every increment of sockindex if it is still
+  valid.
+  
+  Fix Coverity error CID 56878
+  
+  Signed-off-by: Gregor Jasny <gjasny@googlemail.com>
 
-- local-bind-fixup:  Fix inet_pton warning.
+- [Gregor Jasny brought this change]
+
+  Null check before dereference
   
-  Conditionally include <arpa/inet.h> for inet_pton
-  headers.
+  Fix Coverity error CID 56880
+  
+  Signed-off-by: Gregor Jasny <gjasny@googlemail.com>
+
+Jakub Hrozek (28 Jul 2014)
+- [Gisle Vanem brought this change]
+
+  Comment in ares_ipv6.h
+
+David Drysdale (25 Jul 2014)
+- CONTRIBUTING: add file to indicate mailing list is preferred
+
+- Add -t u option to ahost
+  
+  Add an option to allow specification of the AF_UNSPEC
+  address family.
+
+Jakub Hrozek (24 Jul 2014)
+- host_callback: Fall back to AF_INET on searching with AF_UNSPEC
+  
+  Previously, when an ares_gethostbyname() searched with AF_UNSPEC and the
+  first AF_INET6 call only returned CNAMEs, the host_callback never
+  retried AF_INET.
+  
+  This patch makes sure than on ARES_SUCCESS, the result of AF_INET6 is
+  taken as authoritative only if the result contains some addresses.
+
+- [David Drysdale brought this change]
+
+  Move memset call below platform-specific declarations
+  
+  A GitHub commenter [1] says that my recent change to ahost.c has
+  problems compiling on Windows + C89 platforms.
+  
+  [1]  https://github.com/bagder/c-ares/commit/ee22246507c9#commitcomment-6587616
+
+- [David Drysdale brought this change]
+
+  Update ahost man page to describe -s option.
+  
+  Commit ee22246507c9 added the -s <domain> option to the
+  ahost command, but neglected to update the man page to
+  describe it.
+  
+  Also fix typo in description of -t option.
+
+- ares_parse_soa_reply: Do not leak rr_name on allocation failure
+  
+  If ares_malloc_data failed, already allocated rr_name would go out of
+  scope.
+
+- [David Drysdale brought this change]
+
+  Don't override explicitly specified search domains
+  
+  Only set search domains from /etc/resolv.conf if there isn't a value
+  already present in the channel.
+
+- [David Drysdale brought this change]
+
+  Allow specification of search domain in ahost
+  
+  Add the "-s domain" command line option to override the search
+  domains.
+
+Daniel Stenberg (12 May 2014)
+- Revert "ares_parse_aaaa_reply: fix leak when reply contains 1 alias and no address"
+  
+  This reverts commit 440110b303fdbfadb3ad53d30eeb98cc45d70451.
+
+- [Frederic Germain brought this change]
+
+  ares_parse_aaaa_reply: fix leak when reply contains 1 alias and no address
+
+- [Doug Kwan brought this change]
+
+  ares_build.h: fix building on 64-bit powerpc
+  
+  There are two issues.
+  
+  1. gcc actually does not use __ppc__ and __ppc64__ but __PPC__ and
+  __PPC64__.  The tests of __ILP32__ and __LP64__ are sufficient for gcc.
+  
+  2. clang defines __GNU__ and defines both __ppc64__ and __ppc__ when
+  targeting ppc64.  This makes CARES_SIZEOF_LONG to be 4 on a ppc64 system
+  when building with clang.
+  
+  My patch is two change the order of the checks so that we check the
+  64-bit case first.
+
+- refresh: updated now with automake 1.14
+
+- [David Drysdale brought this change]
+
+  single_domain: Invalid memory access for empty string input
+  
+  We noticed a small buglet in ares_search() when it gets an empty string
+  as input -- the single_domain() utility function in ares_search.c
+  accesses invalid memory (before the start of the string).
+
+Guenter Knauf (31 Aug 2013)
+- Fixed warning 'type specifier missing'.
+
+Daniel Stenberg (30 Aug 2013)
+- [Tor Arntsen brought this change]
+
+  ares_rules.h: CARES_SIZEOF_LONG doesn't exist anymore, don't test for it
   
-  Signed-off-by: Ben Greear <greearb@candelatech.com>
+  It was removed in f19387dd72432
 
-- build:  Enable compiling with -Werror.
+- nowarn: use <limits.h> instead of configure for size of long
   
-  This helps find compile warnings because they simply break
-  the build.
+  This makes the header file much more multi-arch friendly and can be used
+  as-is with both 32 bit and 64 bit builds.
+
+- timeoffset: made static and private
   
-  To use:
-  ./configure --enable-warnings --enable-werror
+  ares__timeoffset() was only used once within this single source file
+
+- timeadd: make static
   
-  Signed-off-by: Ben Greear <greearb@candelatech.com>
+  ares__timeadd() was only ever used from within the same source
 
-- ipv6: Fix some build issues related to the local-bind feature.
+Yang Tse (18 Jul 2013)
+- xc-am-iface.m4: comments refinement
+
+- configure: fix 'subdir-objects' distclean related issue
   
-  Signed-off-by: Ben Greear <greearb@candelatech.com>
+  See XC_AMEND_DISTCLEAN comments for details.
 
-Guenter Knauf (29 Jul 2010)
-- Replaced uint32_t with unsigned int to fix broken builds on a couple of platforms.
+- configure: automake 1.14 compatibility tweak (use XC_AUTOMAKE)
 
-Daniel Stenberg (18 Jul 2010)
-- [Ben Greear brought this change]
+- xc-am-iface.m4: provide XC_AUTOMAKE macro
 
-  local-bind:  Support binding to local interface/IPs
+Daniel Stenberg (12 May 2013)
+- gitignore: ignore all ares_*pdf but also CHANGES.dist
+
+- bump: start working towards 1.10.1
+
+Version 1.10.0 (12 May 2013)
+
+Daniel Stenberg (12 May 2013)
+- RELEASE-NOTES: two more bug fixes
+
+- [Keith Shaw brought this change]
+
+  ares_set_servers_csv: fixed IPv6 address parsing
   
-  Add 3 new functions to set the local binding for the out-going
-  socket connection, and add ares_set_servers_csv() to set a
-  list of servers at once as a comma-separated string.
+  Fixed bug that caused the last part of an IPv6 address to be parsed as
+  the port number when the last part is all numeric.
+
+- nroff: fix two syntax mistakes
   
-  Signed-off-by: Ben Greear <greearb@candelatech.com>
+  ares_parse_a_reply and ares_parse_aaaa_reply both had two \fB instead of
+  \fP
+  
+  Reported-by: Alexander Klauer
+  Bug: http://c-ares.haxx.se/mail/c-ares-archive-2013-03/0010.shtml
 
-- version: now start on 1.7.4
+- [Alex Loukissas brought this change]
 
-- [Andrew C. Morrow brought this change]
+  build: fix build on msvc11
 
-  fix memory leak in ares_getnameinfo
+- Makefile.am: increment -version-info for 1.10.0 release
 
-Version 1.7.3 (11 Jun 2010)
+- README: remove unnecessary comment
 
-Daniel Stenberg (11 Jun 2010)
-- changelogs: updated for 1.7.3
+- ares_version.h: copyright end range year is now 2013
 
-- [BogDan Vatra brought this change]
+- RELEASE-NOTES: synced with fb0737f3a0a1c37
 
-  init: allow c-ares to work on Android OS
+- [Paul Saab brought this change]
 
-- changelog: fill in the 1.7.2 changes
+  ares_parse_aaaa_reply: Plug memory leak
+  
+  This change is similar to ares_parse_a_reply.c in commit
+  bffd67f16a8f42fe6dbf79ab2e39d92eea05c8a6
 
-- added another pdf to ignore
+- [Patrick Valsecchi brought this change]
 
-Yang Tse (11 Jun 2010)
-- add ares_parse_mx_reply.c to VS dsp file
+  ares_parse_txt_reply: return a ares_txt_reply node for each sub-string
+  
+  Previously, the function would wrongly return all substrings merged into
+  one.
 
-Daniel Stenberg (10 Jun 2010)
-- tarball: add $(CSOURCES) $(HHEADERS) to EXTRA_DIST
+- [Alexander Klauer brought this change]
+
+  library init: documentation update
   
-  It's not clear to me why we need this, but we apparently may
-  otherwise not get all files bundled in the dist tarball.
+  This commit updates the documentation of ares_library_init() and
+  ares_library_cleanup() with regard to the newly introduced reference
+  counting of initializations and deinitializations.
 
-- version: start working on 1.7.3
+- [Alexander Klauer brought this change]
 
-Version 1.7.2 (10 Jun 2010)
+  library init: be recursive
+  
+  Previously, a single call to ares_library_cleanup() would deinitialise
+  the c-ares library, regardless of how many times ares_library_init() was
+  called. This behaviour may cause problems in programs linking two or
+  more libraries which, in turn, use c-ares. The present commit fixes this
+  problem, deinitializing the library only after a number of calls to
+  ares_library_cleanup() matching the number of calls to
+  ares_library_init().
 
-Daniel Stenberg (10 Jun 2010)
-- RELEASE-NOTES: 1.7.2 details added
+- [Patrick Valsecchi brought this change]
 
-- [Jakub Hrozek brought this change]
+  protocol parsing: check input data stricter
+  
+  ... so that bad length fields aren't blindly accepted
+  
+  Bug: http://c-ares.haxx.se/mail/c-ares-archive-2013-04/0016.shtml
 
-  ares_init: Last, not first instance of domain or search should win
+Guenter Knauf (11 Apr 2013)
+- Create ares_build.h when buidling from Git.
 
-- style: make code less than 80 columns wide
+- Added -DCARES_STATICLIB to CFLAGS.
+  
+  Currently this static makefile does only support building the
+  static library libcares.a.
 
-Yang Tse (31 May 2010)
-- [Tor Arntsen brought this change]
+Daniel Stenberg (8 Apr 2013)
+- [Alexander Klauer brought this change]
 
-  improve alternative definition of bool to use enum instead of unsigned char
+  .gitignore: ignore patch files
+  
+  This commit adds a line to .gitignore to the effect that patch files
+  generated by 'git format-patch' are excluded from the repository.
 
-- fix VS2010 compiler warnings
+- [Alexander Klauer brought this change]
 
-Daniel Stenberg (18 Apr 2010)
-- [Jérémy Lal brought this change]
+  ares_destroy() documentation: no new requests
+  
+  Clarify that no new requests may be added to a resolver channel that is
+  currently being destroyed.
 
-  added ares_parse_mx_reply
+- [Alexander Klauer brought this change]
 
-- repair the file mode
+  Documentation: properly document ARES_ECANCELLED
+  
+  This commit clarifies the behaviour of ares_cancel() with respect to
+  callbacks and adds missing documentation of ARES_ECANCELLED to the man
+  pages of the affected functions.
 
-- remove all $Id$ lines
+- [Alexander Klauer brought this change]
 
-- remove all .cvsignore files
+  ares_cancel(): cancel requests safely
+  
+  An invocation of ares_cancel() walks through the request list, calling
+  the callbacks of all pending requests on a channel. Previously, if such
+  a callback added a new request to the channel, the request list might
+  not end up empty, causing an abort by assertion failure. The present
+  commit ensures that precisely all requests present upon entry of
+  ares_cancel() are cancelled, and that adding new requests through
+  callbacks is safe.
 
-- spell fix
+Yang Tse (10 Mar 2013)
+- ares.h: stricter CARES_EXTERN linkage decorations logic
   
-  reported by Gregor Jasny on the mailing list
+  No API change involved.
 
-- [Peter Pentchev brought this change]
+- ares_build.h.dist: enhance non-configure GCC ABI detection logic
+  
+  GCC specific adjustments:
+  
+  - check __ILP32__ before 32 and 64bit processor architectures in
+    order to detect ILP32 programming model on 64 bit processors
+    which, of course, also support LP64 programming model, when using
+    gcc 4.7 or newer.
+  
+  - keep 32bit processor architecture checks in order to support gcc
+    versions older than 4.7 which don't define __ILP32__
+  
+  - check __LP64__ for gcc 3.3 and newer, while keeping 64bit processor
+    architecture checks for older versions which don't define __LP64__
 
-  Fix a couple of typos and grammar nits.
+Daniel Stenberg (9 Mar 2013)
+- ares.h: there is no ares_free_soa function
 
-- ignore the GPG signature files too
+Yang Tse (9 Mar 2013)
+- Makefile.am: empty AM_LDFLAGS definition for automake 1.7 compatibility
 
-- start the journey towards 1.7.2
+- ares_inet_ntop.3: s/socklen_t/ares_socklen_t
 
-- no longer CVS tagging
+- configure: use XC_LIBTOOL for portability across libtool versions
 
-- ignore generated PDFs
+- xc-lt-iface.m4: provide XC_LIBTOOL macro
 
-Version 1.7.1 (23 Mar 2010)
+- Makefile.am: use AM_CPPFLAGS instead of INCLUDES
 
-Daniel Stenberg (23 Mar 2010)
-- 1.7.1
+- inet_ntop.c: s/socklen_t/ares_socklen_t
 
-- made README the primary readme file
+- inet_ntop.c: s/socklen_t/ares_socklen_t for portability
+
+Daniel Stenberg (19 Feb 2013)
+- ares.h: s/socklen_t/ares_socklen_t for portability
+
+- ares_inet_ntop.3: 4th argument is socklen_t!
+
+- spell inet correctly!
+
+- ares_inet_pton/ntop: cleanup
   
-  ... and did README.cares to contain a historic reason etc.
+  Make sure that the symbols are always exported and present in c-ares.
+  
+  Make the headers prefixed with 'ares'.
+  
+  Removed the inet_ntop.h version as it no longer features any content.
 
-- s/CVS/git
+- ares_inet_ntop/ares_inet_pton: added man pages
 
-- git now, not CVS
+Yang Tse (15 Feb 2013)
+- [Gisle Vanem brought this change]
 
-- ignore lots of generated files
+  curl_setup_once.h: definition of HAVE_CLOSE_S defines sclose() to close_s()
 
-- [Daniel Johnson brought this change]
+- [Gisle Vanem brought this change]
 
-  Fix warnings for clang
+  config-dos.h: define HAVE_CLOSE_S for MSDOS/Watt-32
 
-Yang Tse (17 Mar 2010)
-- replaced intel compiler option -no-ansi-alias with -fno-strict-aliasing
+- [Gisle Vanem brought this change]
 
-- update outdated serial number
+  config-dos.h: define strerror() to strerror_s_() for High-C
 
-- fix compiler warning
+Daniel Stenberg (13 Feb 2013)
+- ares_get_datatype: removed unused function
+  
+  it was also wrongly named as internal functions require two underscores
 
-- watt32 compilation fix
+- ares__bitncmp: use two underscores for private functions
+  
+  It used a single one previously making it look like a public one
 
-- Added another VS10 version string
+- ares__generate_new_id: moved to ares_query.c
+  
+  ... and ares__rc4 is turned into a local static function.
 
-- fix line break
+- ares__swap_lists: make private and static
+  
+  ... since there's only one user, make it static within ares_process.c
+
+Yang Tse (13 Feb 2013)
+- Makefile.msvc: add four VS version strings
+
+Daniel Stenberg (13 Feb 2013)
+- ares_expand_name.3: clarify how to free the data
 
-- removed usage of 's6_addr', fixing compilation issue triggered with no
-  longer using 'in6_addr' but only our 'ares_in6_addr' struct
+Yang Tse (30 Jan 2013)
+- zz40-xc-ovr.m4: fix 'wc' detection - follow-up 2
+  
+  - Fix a pair of single quotes to double quotes.
+  
+  URL: http://curl.haxx.se/mail/lib-2013-01/0355.html
+  Reported by: Tor Arntsen
 
-Daniel Stenberg (5 Mar 2010)
-- Daniel Johnson provided fixes for building with the clang compiler
+- zz40-xc-ovr.m4: fix 'wc' detection - follow-up
+  
+  - Take into account that 'wc' may return leading spaces and/or tabs.
+  
+  - Set initial IFS to space, tab and newline.
 
-Yang Tse (5 Mar 2010)
-- Added IPv6 name servers support
+- zz40-xc-ovr.m4: fix 'wc' detection
+  
+  - Take into account that 'wc' may return leading spaces.
+  
+  - Set internationalization behavior variables.
+  
+  Tor Arntsen analyzed and reported the issue.
+  
+  URL: http://curl.haxx.se/mail/lib-2013-01/0351.html
 
-Gisle Vanem (5 Mar 2010)
-- Ops!. Readded ares_nowarn.h.
+- zz40-xc-ovr.m4: check another three basic utilities
 
-- Added ares_nowarn.c.
+- zz40-xc-ovr.m4: 1.0 interface stabilization
+  
+  - Stabilization results in 4 public interface m4 macros:
+    XC_CONFIGURE_PREAMBLE
+    XC_CONFIGURE_PREAMBLE_VER_MAJOR
+    XC_CONFIGURE_PREAMBLE_VER_MINOR
+    XC_CHECK_PATH_SEPARATOR
+  - Avoid one level of internal indirection
+  - Update comments
+  - Drop XC_OVR_ZZ40 macro
 
-Yang Tse (28 Feb 2010)
-- Added SIZEOF_INT and SIZEOF_SHORT definitions for non-configure systems
+- zz40-xc-ovr.m4: emit witness message in configure BODY
+  
+  This avoids witness message in output when running configure --help,
+  while sending the message to config.log for other configure runs.
 
-- Added ares_nowarn.* to VC6 project file
+- zz40-xc-ovr.m4: truly do version conditional overriding
+  
+  - version conditional overriding
+  - catch unexpanded XC macros
+  - fix double words in comments
 
-- Added SIZEOF_INT definition
+- zz40-xc-ovr.m4: fix variable assignment of subshell output bashism
+  
+  Tor Arntsen analyzed and reported the issue.
+  
+  URL: http://curl.haxx.se/mail/lib-2013-01/0306.html
 
-- fix compiler warning
+- zz40-xc-ovr.m4: reinstate strict AC_REQUIRE macro dependencies
 
-- fix compiler warning
+- zz40-xc-ovr.m4: avoid double single-quote usage
 
-- fix compiler warning
+- zz40-xc-ovr.m4: parentheses balancing of 'case' statements
+  
+  m4 quadrigraph shell comment technique allows proper autoconf
+  parentheses balancing in shell 'case' statements. The presence
+  of unbalanced parentheses may otherwise trigger expansion bugs.
 
-Daniel Stenberg (17 Feb 2010)
-- ares_reinit()
+- zz40-xc-ovr.m4: internals overhauling
   
-  - To allow an app to force a re-read of /etc/resolv.conf etc, pretty much
-    like the res_init() resolver function offers
+  - Update comments
+  - Execute commands in subshells
+  - Faster path separator check
+  - Fix missing 'test' command
+  - Rename private macros
+  - Minimize AC_REQUIRE usage
 
-- - Tommie Gannert pointed out a silly bug in ares_process_fd() since it didn't
-    check for broken connections like ares_process() did. Based on that, I
-    merged the two functions into a single generic one with two front-ends.
+- zz40-xc-ovr.m4: redirect errors and warnings to stderr
 
-Yang Tse (30 Dec 2009)
-- VMS specific preprocessor symbol checking adjustments
+- configure: use XC_CONFIGURE_PREAMBLE early checks
+  
+  Some basic checks we make were placed early enough in generated
+  configure script when using autoconf 2.5X versions. Newer autoconf
+  versions expand these checks much further into the configure script,
+  rendering them useless. Using XC_CONFIGURE_PREAMBLE fixes placement
+  of early intended checks across all our autoconf supported versions.
 
-- Mention last changes
+- zz40-xc-ovr.m4: provide XC_CONFIGURE_PREAMBLE macro
 
-- - Fix configure_socket() to use ares_socket_t instead of int data type.
+- configure: autotools compatibility fixes - step I
+  
+  Fix proper macro expansion order across autotools versions for
+  C compiler and preprocessor program checks.
 
-- - Where run-time error checks enabling compiler option /GZ was used it is now
-    replaced with equivalent /RTCsu for Visual Studio 2003 and newer versions.
+- configure: fix automake 1.13 compatibility
   
-  - Compiler option /GX is now replaced with equivalent /EHsc for all versions.
+  Tested with:
+  
+  buildconf: autoconf version 2.69
+  buildconf: autom4te version 2.69
+  buildconf: autoheader version 2.69
+  buildconf: automake version 1.13.1
+  buildconf: aclocal version 1.13.1
+  buildconf: libtool version 2.4
+  buildconf: GNU m4 version 1.4.16
 
-- - Ingmar Runge noticed that Windows config-win32.h configuration file
-    did not include a definition for HAVE_CLOSESOCKET which resulted in
-    function close() being inappropriately used to close sockets.
+- ares_private.h: use again memdebug.h instead of curl_memdebug.h
 
-Daniel Stenberg (30 Nov 2009)
-- start working on 1.7.1
+- configure.ac: replace AM_CONFIG_HEADER with AC_CONFIG_HEADERS
+  
+  automake 1.13 errors if AM_CONFIG_HEADER is used in configure script.
 
-Version 1.7.0 (27 Nov 2009)
+- cares-override.m4: provide AC_CONFIG_MACRO_DIR definition conditionally
+  
+  Provide a 'traceable' AC_CONFIG_MACRO_DIR definition only when using
+  an autoconf version that does not provide it, instead of what we were
+  doing up to now of providing and overriding AC_CONFIG_MACRO_DIR for
+  all autoconf versions.
 
-Yang Tse (27 Nov 2009)
-- Preserve empty line following last target
+- ares_private.h: use curl_memdebug.h instead of memdebug.h
 
-- - Larry Lansing fixed ares_parse_srv_reply to properly parse replies
-    which might contain non-SRV answers, skipping over potential non-SRV
-    ones such as CNAMEs.
+- vc6cares.dsp: add ares_create_query.c and ares_parse_soa_reply.c
 
-- When using icc, compile with -fpic and link with intel dynamic libraries.
+- cares-functions.m4: improve gethostname arg 2 data type check
 
-- Added 'currently' in italics to insist on transient situation.
+- setup_once.h: HP-UX specific 'bool', 'false' and 'true' definitions.
+  
+  Also reverts commit bceb40095a
 
-- Fix language
+- configure: check if compiler halts on function prototype mismatch
 
-- Daniel wants upcoming release to be 1.7.0
+- cares-functions.m4: add gethostname arg 2 data type check and definition
 
-- Mention last changes
+- cares-functions.m4: update thread-safeness detection of getaddrinfo()
+  
+  Take in account that POSIX standard Issue 7 drops h_errno support. Now, we also
+  consider getaddrinfo() to be thread-safe when (_POSIX_C_SOURCE >= 200809L) or
+  (_XOPEN_SOURCE >= 700) independently of whether h_errno exists or not.
+  
+  Take in account that h_errno might be a modifiable lvalue not defined as
+  a C preprocessor macro.
 
-- - Removed from external interface preprocessor symbol definition for
-    CARES_HAVE_ARES_FREE_DATA. Current functionality of ares_free_data()
-    makes it unnecessary.
+- setup_once.h: HP-UX <sys/socket.h> issue workaround
+  
+  Issue: When building a 32bit target with large file support HP-UX
+  <sys/socket.h> header file may simultaneously provide two different
+  sets of declarations for sendfile and sendpath functions, one with
+  static and another with external linkage. Given that we do not use
+  mentioned functions we really don't care which linkage is the
+  appropriate one, but on the other hand, the double declaration emmits
+  warnings when using the HP-UX compiler and errors when using modern
+  gcc versions resulting in fatal compilation errors.
+  
+  Mentioned issue is now fixed as long as we don't use sendfile nor
+  sendpath functions.
 
-- Added README.msvc
+- setup_once.h: refactor inclusion of <unistd.h> and <sys/socket.h>
+  
+  Inclusion of these two header files now done in setup_once.h
 
-- Changed c-ares naming conventions when using MSVC as described in README.msvc
+- Header inclusion clean-up
+  
+  Remove header inclusions already done in setup_once.h
 
-- - Mention other recent changes
+- setup_once.h: HP-UX specific TRUE and FALSE definitions
+  
+  Some HP-UX system headers require TRUE defined to 1 and FALSE to 0.
 
-- - Jakub Hrozek renamed addrttl and addr6ttl structs to ares_addrttl and
-    ares_addr6ttl in order to prevent name space pollution, along with
-    necessary changes to code base and man pages.This change does not break
-    ABI, there is no need to recompile existing applications. But existing
-    applications using these structs with the old name will need source code
-    adjustments when recompiled using c-ares 1.6.1.
+- ares_timeout.c: fix compiler warning
 
-- - Jakub Hrozek fixed more function prototypes in man pages to sync them
-    with the ones declared in ares.h
+- ares_create_query.c: IRIX compilation fix
 
-- Make configure remove the ares_build.h file included in distribution tarballs.
+- c-ares/nameser.h: add some T_* defines for ns_t_* values
 
-- Fix macro redefinition.
+Daniel Stenberg (7 Nov 2012)
+- Revert "ares_parse_aaaa_reply: fix memory leak"
+  
+  This reverts commit 50f25d8a4b2d16f4c5e0ef620238688b7a315c7a.
 
-- Fix name space pollution.
+- ares_parse_aaaa_reply: fix memory leak
+  
+  an allocated buffer was not freed in the successful case.
 
-- Allow using different extra import libraries for debug and release builds.
+- [Gisle Vanem brought this change]
 
-- Add manifest stuff to msvc makefile
+  adig: perror() doesn't work for socket errors on windows
+  
+  ... so print the SOCKERRNO instead
 
-- Sync man page with reality
+- get_DNS_AdaptersAddresses: fix IPv6 parsing
+  
+  Use of the wrong define made the function not parse IPv6 addresses
+  properly.
+  
+  Bug: http://c-ares.haxx.se/mail/c-ares-archive-2012-06/0028.shtml
+  Reported by: Saúl Ibarra Corretgé
 
-- Add missing external API decoration for ares_set_socket_callback()
+- version: bumped to 1.10.0
+  
+  Due to the newly added function: ares_create_query()
 
-- Add ares_free_data() man page.
+- AUTHORS: synced with 83093ac450
+  
+  Added 21 authors since this document was last updated
 
-- - Provide in external interface preprocessor symbol definitions for
-    CARES_HAVE_ARES_FREE_DATA as an indication of function availability.
+- ares_create_query.3: mention when this is added
 
-- Remove typecast
+- [hpopescu@ixiacom.com brought this change]
 
-- Fix comment
+  Added new feature (rfc2671)
 
-- Add ares_data.c and ares_data.h
+- code police: fix indents, < 80 columns, reflowed comments
 
-- Jakub Hrozek modified ares_parse_srv_reply() and ares_parse_txt_reply() API
-  to return a linked lists of results. These were also modified to internally
-  use the ares_data memory struct and as such its result must be free'ed with
-  ares_free_data().
+Guenter Knauf (11 Jul 2012)
+- Cleaned up version awk script.
 
-- Initial support for the generic ares_free_data() function that will allow
-  applications to free memory allocated and returned by some c-ares funtions.
+Daniel Stenberg (30 Jun 2012)
+- [Gisle Vanem brought this change]
 
-- Make usage of calloc()'s arguments consistent with rest of code base
+  read_udp_packets: bail out loop on bad sockets
+  
+  I can see that recvfrom() in ares_process.c many times is called with
+  'udp_socket' == ARES_SOCKET_BAD. The code takes care not to call
+  recv/recvfrom with ARES_SOCKET_BAD in the outer-loop. So should the
+  inner-loop.
+
+Yang Tse (29 Jun 2012)
+- cares-compilers.m4: remove -Wstrict-aliasing=3 from clang
+  
+  Currently it is unknown if there is any version of clang that
+  actually supports -Wstrict-aliasing. What is known is that there
+  are several that don't support it.
 
-- workaround icc 9.1 optimizer issue
+- cares-compilers.m4: -Wstrict-aliasing=3 for warning enabled gcc and clang builds
 
-- Add icc fvisibility bug test
+Daniel Stenberg (18 Jun 2012)
+- version: work towards 1.9.2 (at least)
 
-- Fix icc 9.0 compiler warning: external definition with no prior declaration
+Version 1.9.1 (18 Jun 2012)
 
-- Fix three var names
+Daniel Stenberg (18 Jun 2012)
+- RELEASE-NOTES: 1.9.1 coming up
 
-- Add check for assert.h header file
+Version 1.9.0 (16 Jun 2012)
 
-- getaddrinfo is fully thread safe on solaris versions which
-  implement the function even when h_errno is not a macro.
-  
-  The h_errno macro test now only done on systems for which there
-  is no hard coded knowledge about getaddrinfo's thread safeness.
+Daniel Stenberg (16 Jun 2012)
+- ares_version.h: next version is 1.9.0
 
-- Remove files generated on previous buildconf/configure run
+- [Marko Kreen brought this change]
 
-- Remove enable-thread / disable-thread configure option. These were only placebo
-  options. The library is always built as thread safe as possible on every system.
+  ares_data.h: ARES_DATATYPE_SOA_REPLY is added in 1.9.0
 
-- Refactor how preprocessor symbol _THREAD_SAFE definition is done.
+- RELEASE-NOTES: synced with 979bf951d
+  
+  Next release deemed to become 1.9.0 due to the new function
 
-- Assume that getaddrinfo is thread safe, unless hard coded
-  knowledge says the contrary or h_errno is not defined.
+- [Marko Kreen brought this change]
 
-- Related with the threadsafe capability of getaddrinfo:
-  
-  - Constantine Sapuntzakis reported that Darwin 6.0 a.k.a. MAC OS X 10.2
-    and newer have a threadsafe getaddrinfo.
+  SOA parser added
   
-  - Fix Dragonfly BSD triplet detection.
+  I need to do SOA queries, so here is a parser for them.
   
-  - In case the hard-coded knowledge says that getaddrinfo is threadsafe,
-    an additional check is done to verify that h_errno is also defined.
-    If h_errno isn't defined, we finally assume that it isn't threadsafe.
-    Jamie Lokier provided the inspiration for this extra check.
+  - ares_soa_reply: new struct
+  - ares_malloc_data/ares_free_soa: ARES_DATATYPE_SOA_REPLY
+  - ares_parse_soa_reply: actual function
 
-- AIX 5.2 and newer have threadsafe getaddrinfo.
-  
-  Add some comments to better understand what the regex's pretend to achieve.
+Yang Tse (14 Jun 2012)
+- Kill compiler warning
 
-- HP-UX 11.11 and later have threadsafe getaddrinfo
+- Fix libcares.pc generation for static MingW* cross builds
 
-- Check if getaddrinfo is threadsafe when function check allows it to be used
+Daniel Stenberg (21 May 2012)
+- [Nick Alcock brought this change]
 
-- Renamed fpGetNetworkParams and fpSystemFunction036 to avoid namespace pollution with static library
+  Fix UDP and TCP port byte order in saved options.
+  
+  The UDP and TCP port are stored in network byte order in the
+  ares_channeldata, but are passed in to ares_init_options() in host byte
+  order.  Thus we must return them from ares_save_options() in host byte
+  order too, or a duplicated channel will convert them again, leading to a
+  nonfunctional channel and a mysterious connection refused error from
+  ares_gethostbyname().  This breaks ares_dup(), thus the curl easy API
+  when c-ares is used by curl, and thus all the curl easy API's users.
 
-- Add kernel32.lib
+Yang Tse (28 Apr 2012)
+- version: start working on 1.8.1-DEV
 
-- Mention last changes
+Version 1.8.0 (27 Apr 2012)
 
-- Reinstate copyright symbol lost in previous commit
+Daniel Stenberg (27 Apr 2012)
+- RELEASE-NOTES: call next 1.8 instead
+  
+  Since we added a function, let's use a stricter bumping scheme
 
-- Make some strings different in resource file for debug or release builds
+Yang Tse (25 Apr 2012)
+- INSTALL: some adjustments
 
-- Ignore more subdirs
+Daniel Stenberg (25 Apr 2012)
+- GIT-INFO: mention buildconf
 
-- Fix compiler warning: conditional expression is constant
+Yang Tse (25 Apr 2012)
+- INSTALL: remove more sections that don't apply to c-ares
 
-- Sync linker and resource compiler options with Makefile.msvc
+- ares_timeout.c: fix compiler warning
 
-- Follow Makefile.msvc subdirectory naming scheme, and sync compiler options
+Daniel Stenberg (25 Apr 2012)
+- [Ben Noordhuis brought this change]
 
-- Updated MSVC makefile that allows building dynamic and static
-  c-ares libraries in debug and release flavours.
+  Makefile.m32: fix mingw32 build
   
-  Additionally each of the three sample programs is built against
-  each of the four possible c-ares libraries, generating all this
-  a total number of 12 executables and 4 libraries.
-
-- Test for USE_WINSOCK since it is more restrictive than WIN32
+  * add . to include path so ares_build.h is picked up
+  * make ar configurable to ease cross-compiling
 
-- Make header inclusion depend on HAVE_*_H definition
+- RELEASE-NOTES: added what's happened since 1.7.5
 
-- Remove unneeded preprocessor directives
+Guenter Knauf (22 Apr 2012)
+- Updated copyright year.
 
-- Adjust c-ares include paths for memory tracking enabled (--enable-curldebug) builds
+Yang Tse (21 Apr 2012)
+- ares_init.c: Further refactoring of Windows system's DNS fetching code
 
-- source files used by sample programs
+Guenter Knauf (20 Apr 2012)
+- Android: small changes to dns property part.
+  
+  Prefix prop vars; kill var; use DNS_PROP_NAME_PREFIX macro.
 
-- Renamed c-ares setup.h to ares_setup.h
+- Handle CNAME-only in ares_parse_aaaa_reply().
+  
+  posted to the c-ares list by Peter Griess <pg@std.in>.
 
-- Adjust include paths to take in account that currently:
+- Add support for multiple DNS servers on Android.
   
-  c-ares with --enable-curldebug uses memdebug.h from libcurl's lib subdirectory.
+  Before, c-ares always used the first DNS server on Android, causing
+  network problems if this DNS server was not available.
   
-  memdebug.h needs access to libcurl's setup.h from libcurl's lib subdirectory
-  and also needs access to libcurl's generated curl_config.h
+  Signed-off-by: Geert Uytterhoeven <Geert.Uytterhoeven@sonycom.com>
 
-- Undo old temporary change once used for testing purposes
+- Added INSTALL so it gets into tarballs.
 
-- Mention many changes
+- Added some more ifdefs to silent compiler warnings.
 
-- Mention --enable-symbol-hiding configure option
+Yang Tse (17 Apr 2012)
+- INSTALL: remove a non c-ares section
 
-- Symbol hiding configure options renamed to the hopefully less ambiguous
-  --enable-symbol-hiding and --disable-symbol-hiding as well as related
-  macro names and some internal variables used for them.
+- cares-compilers.m4: -Wno-pedantic-ms-format for Windows gcc 4.5 builds
   
-  Related configuration file preprocessor symbols named to
-  CARES_SYMBOL_HIDING and CARES_SYMBOL_SCOPE_EXTERN.
-
-- Header inclusion depending on HAVE_* symbol.
-  Fix two typos.
+  When building a Windows target with gcc 4.5 or newer and strict compiler
+  warnings enabled use -Wno-pedantic-ms-format in addition to other flags.
 
-- Comparison of the Initial revision of this file with ares_parse_a_reply.c
-  shows that this one is actually a modified copy of ares_parse_a_reply.c.
+- setup_once.h: tighten requirements for stdbool.h header inclusion
   
-  In order to comply with ares_parse_a_reply.c's M.I.T. license, the old
-  1998 M.I.T. copyright notice is now also preserved in this file the same
-  as it is done in other ares_parse_*.c files.
-
-- Add CVS Id tag.
-  Fix identation of some license lines.
+  Include stdbool.h only when it is available and configure is capable of
+  detecting a proper 'bool' data type when the header is included.
 
-- Add CVS Id tag.
+- configure: NATIVE_WINDOWS no longer defined in config file
 
-- Fix comment
+- cares-compilers.m4: double underscore decoration for visibility attribute
 
-- In no particular order, changed/fixed all of the following in
-  ares_parse_txt_reply() current version:
-  
-  - Fixed a couple of potential double free's.
-  
-  - Fixed memory leaks upon out of memory condition.
-  
-  - Fixed pointer arithmetic.
-  
-  - Setting ntxtreply to zero upon entry for all failure cases.
-  
-  - Changed data type to size_t for variables substr_len, str_len and
-    the length member of ares_txt_reply struct.
-  
-  - Avoided a couple of memcpy() calls.
-  
-  - Changed i data type to unsigned int to prevent compiler warnings.
-  
-  - Adjusted a comment.
+- build adjustments: CARES_SYMBOL_HIDING no longer defined in config files
   
-  - Use ARES_SUCCESS literal for successfull completion.
+  configure script now provides conditional definitions for Makefile.am
+  that result in CARES_SYMBOL_HIDING being defined by resulting makefiles
+  when appropriate.
+
+- configure: Windows cross-compilation fixes
   
-  - Added CVS Id tag.
+  CARES_BUILDING_LIBRARY and CARES_STATICLIB no longer defined in ares_config.h,
+  configure will generate appropriate conditionals so that mentioned symbols
+  get defined and used in Makefile derived from Makefile.am at compilation time.
 
-- Add c-ares DLL resource file to distribution archive
+Guenter Knauf (17 Apr 2012)
+- Added INSTALL file adapted from libcurl.
+  
+  Not yet ready, and needs further edits.
 
-- ignore files
+Yang Tse (16 Apr 2012)
+- ares_init.c: get_iphlpapi_dns_info() refactoring
 
-- Empty subdir
+Guenter Knauf (16 Apr 2012)
+- Kill some more compiler warnings.
 
-- Updated MSVC 6.0 workspace and project files that allows building
-  dynamic and static c-ares libraries in debug and release flavours.
-  
-  Additionally each of the three sample programs is built against
-  each of the four possible c-ares libraries, generating all this
-  a total number of 12 executables and 4 libraries.
+- Kill compiler warning about unused var.
 
-Daniel Stenberg (29 Oct 2009)
-- no need to check for NULL pointers before dereferencing, as the pointers
-  MUST be valid and they are dereferenced further down in the function
-  unconditionally!
+- Fixed my last commit: wrong preprocessor directive.
 
-- shorten the descriptions somewhat
+- Check for __ANDROID__ in addition to ANDROID macro.
 
-- update to the new struct name
+- Check for __ANDROID__ in addition to ANDROID macro.
+  
+  Posted to c-ares list by Wayne.
 
-- Jakub Hrozek added ares_parse_txt_reply() for TXT parsing
+- Fix for Android to disable useless arpa/nameser.h.
 
-- use 'ares_srv_reply' for proper name-spacing
+- Fix for Android to include sys/select.h for fd_set.
 
-Yang Tse (29 Oct 2009)
-- Add reference for ares_parse_srv_reply.pdf
+Yang Tse (17 Mar 2012)
+- ares_data.c: some NAPTR related fixes
 
-- Add reference for ares_parse_srv_reply docs
+Daniel Stenberg (16 Mar 2012)
+- port numbers: convert them to network order!
+  
+  When the config options ARES_OPT_UDP_PORT or ARES_OPT_TCP_PORT are used,
+  make sure to convert them to network byte order!
+  
+  Bug: http://c-ares.haxx.se/mail/c-ares-archive-2012-02/0004.shtml
 
-- External API function linkage decoration adjustment
+- white space cleanup
+  
+  - Keep code within 80 columns
+  
+  - Removed funny spaces after open paren and before closing paren
 
-- External API function linkage decoration adjustment
+- [Poul Thomas Lomholt brought this change]
 
-- Initial step towards the ability to reduce c-ares exported symbols
-  based on the 'visibility' attribute for GNUC and __global for Sun
-  compilers, taking also in account __declspec function decoration
-  for Win32 and Symbian DLL's.
+  get_iphlpapi_dns_info: fix buffer overrun
   
-  Introducing configure options --enable-hidden-symbols and
-  --disable-hidden-symbols following libcurl's naming.
+  I experienced a buffer overrun exception in c-ares on Windows and
+  tracked it down to be an error in the calculation of the 'left' variable
+  in get_iphlpapi_dns_info().
+  
+  I changed the variable type of 'left' to a _signed_ type because of the
+  subtraction arithmetic; not sure if a long is the best choice
 
-- Fix comment
+- Merge pull request #7 from saghul/naptr
+  
+  Added support for parsing NAPTR records
 
-- Fix spelling
+saghul (23 Feb 2012)
+- Added support for parsing NAPTR records
 
-- Fix Pelles C Win32 target compilation issues
+Yang Tse (19 Jan 2012)
+- ares_init.c: fix compiler warning on winsock builds
 
-- John Engelhart noticed an unreleased problem relative to a duplicate
-  ARES_ECANCELLED error code value and missing error code description.
+- configure: libtool 1.5 tweaks
 
-- Fix compiler warning: local variable may be used without having been initialized
+Daniel Stenberg (19 Dec 2011)
+- ares_timeout.3: fix the NAME section
+  
+  It was clearly a copy n' paste error
 
-- Use *_CHECK_PATH_SEPARATOR_REQUIRED to ensure that *_CHECK_PATH_SEPARATOR
-  is only expanded and included once in the configure script.
+Yang Tse (27 Sep 2011)
+- [Albert Chin brought this change]
 
-- Our _AS_PATH_SEPARATOR_PREPARE override is now m4_defun'd instead of m4_define'd
-  due to autoconf 2.64 m4_require'ing it in _AS_SHELL_SANITIZE indirectly through
-  _AS_PATH_WALK.
+  configure - m4: make CURL_CHECK_DEF ignore leading whitespace on symbol def
+  
+  When using Sun C compiler the preprocessor somehow inserts an extra space
+  in front of replaced symbol, breaking CURL_CHECK_DEF macro. To workaround
+  this, macro CURL_CHECK_DEF now ignores all leading whitespace in front of
+  symbol substitution result.
 
-- Fix compiler warning: argument is incompatible with corresponding format string conversion
+- ares_init.c: fix segfault triggered in ares_init_options() upon previous
+               failure of init_by_defaults() and incomplete cleanup there.
 
-- Fix potential out-of-bounds read
+- ares_process.c: fix compiler warning
 
-- Fix compiler warning: loop without body
+- fix MSVC compiler warning 'conditional expression is constant'
 
-- Fix compiler warning
+- setup_once.h cleanup and sync
 
-- Fix compiler warning
+- [Denis Bilenko brought this change]
 
-- Fix compiler warning
+  ares_getnameinfo: fix random results with c-ares 1.7.5
+  
+  In ares_getnameinfo memcpy did not copy enough bytes, causing
+  it to return arbitrary memory contents as a result.
 
-- Fix compiler warning: addition result could be truncated before cast to bigger sized type
+- warnings: fix another 'conversion may lose significant bits' compiler warning
 
-- Overhauled ares__get_hostent()
+- ares_dns.h: adjust DNS__16BIT and DNS__32BIT macro definitions
   
-  - Fixing out of bounds memory overwrite triggered with malformed /etc/hosts file.
-  - Improving parsing of /etc/hosts file.
-  - Validating requested address family.
-  - Ensuring that failures always return a NULL pointer.
-  - Adjusting header inclusions.
+  Fixing compiler warnings existing definitions triggered on these.
 
-- Fix ssize_t redefinition errors on WIN64 reported by Alexey Simak
+- ares_destroy.c: fix segfault in ares_destroy_options()
 
-- more files to ignore
+Daniel Stenberg (21 Aug 2011)
+- ares_parse_srv_reply: silence compiler warnings
+  
+  ... by adding ugly typecasts.
 
-- Check if _REENTRANT definition is required to
-  make errno available as a preprocessor macro.
+- CHANGES: generate from script
+  
+  The CHANGES file is now generated automatically with 'git2changes.pl',
+  invoked by the maketgz script which is used to build release archives.
+  
+  The former human edited CHANGES file was renamed to CHANGES.0 in git.
 
-- Attempt to silence bogus compiler warning: "Potential null pointer dereference"
+Yang Tse (21 Aug 2011)
+- Makefile.netware: SIZEOF_SHORT definition
 
-- ignore more files
+- warnings: fix some 'conversion may lose significant bits' compiler warnings
 
-Gisle Vanem (7 Sep 2009)
-- Suppress warnings about unused prototypes in Watt32 and Win32 programs.
+- configure: fix symbol hiding usability check
+  
+  A more thorough test is done now in order to determine visibility attribute
+  usability, given that some compilers don't support visibility attribute on
+  all configurations.
 
-- Update email address.
+Daniel Stenberg (16 Aug 2011)
+- 1.7.6: start working...
 
-- Update my email address. Add ares_config.h as dependency for 'make depend'.
+Version 1.7.5 (16 Aug 2011)
 
-Yang Tse (6 Sep 2009)
-- T_SRV portability check
+Daniel Stenberg (16 Aug 2011)
+- CHANGES: synced for 1.7.5 release
 
-Gunter Knauf (5 Sep 2009)
-- changed includes to match style how we do with all other *.c files.
+- RELEASE-NOTES: synced with bb4096effef7f000
 
-- changed u_int16_t to unsigned short because it is the only place within ares and curl where such a type would be used;
-  also it broke many autobuilds. We should probably introduce an ares_port_t if we want to use a type here.
+Jakub Hrozek (15 Aug 2011)
+- Only fall back to AF_INET searches when looking for AF_UNSPEC addresses
 
-Gisle Vanem (5 Sep 2009)
-- Replace 'uint16_t' with 'u_int16_t' since the latter is used in ares.h.
+Yang Tse (10 Aug 2011)
+- [Gisle Vanem brought this change]
 
-- Added 'ares_parse_srv_reply.obj'. Added definition of 'u_int16_t'. This is I don't like; we should not depend on such non-universal types in a public header. But this is just a quick fix.
+  ares_iphlpapi.h: Watcom C fix
+  
+    Added "!defined(_WS2DEF_)" since Watcom doesn't have
+    a per type guard for the typedefs 'CSADDR_INFO' (that MingW has) or
+    'SOCKET_ADDRESS' (that MSVC has). But we can use the header-guard for
+    <ws2def.h> instead.
 
-Daniel Stenberg (4 Sep 2009)
-- - Jakub Hrozek added ares_parse_srv_reply() for SRV parsing
+- [Gisle Vanem brought this change]
 
-Steinar H. Gunderson (27 Aug 2009)
-- Support lookup of IPv4 literals in ares_gethostbyname(), even when the address family is set to AF_INET6.
+  Makefile.Watcom:
+    * The 'NTDDI_VERSION' needs to be raised to 0x05010000
+      in order for SOCKADDR_STORAGE etc. to be typedefed.
+    * Replaced '-dUSE_WATT32' with '-dWATT32'.
+    * Added $(DEMOS) to the 'all' target and removed the 'demos'
+      target to be consistent with e.g. Makefile.msvc etc.
+    * 'ENABLE_IPV6' is no longer used. Hence removed the '%use_ipv6' construct.
+    * object-file order seems to be important (Watcom v.19). Hence
+      'ares_getopt.obj' must be put after the .obj that references getopt().
 
-Gisle Vanem (3 Aug 2009)
-- Remove call to LoadLibrary(). (leftover from debugging).
+- cares-compilers.m4: CARES_CONVERT_INCLUDE_TO_ISYSTEM adjustments
+  
+  Add CARES_CHECK_COMPILER as a requirement.
+  
+  Ensure macro does nothing unless GNU_C or CLANG compiler is used.
+  
+  This should allow usage of this macro in unforeseen placements.
 
-- Fix bad sentence.
+- config-win32.h: comments adjustments - followup
 
-Daniel Stenberg (3 Aug 2009)
-- - Timo Teras changed the reason code used in the resolve callback done when
-    ares_cancel() is used, to be ARES_ECANCELLED instead of ARES_ETIMEOUT to
-    better allow the callback to know what's happening.
+- config-win32.h: comments adjustments
 
-- - Joshua Kwan fixed the init routine to fill in the defaults for stuff that
-    fails to get inited by other means. This fixes a case of when the c-ares
-    init fails when internet access is fone.
+Daniel Stenberg (5 Aug 2011)
+- [Tom Hughes brought this change]
 
-Gunter Knauf (16 Jul 2009)
-- test if adding ../lib to includes can fix the current break ...
+  ares_parse_a_reply: fix memleak
 
-- renamed generated config.h to ares_config.h in order to avoid clashes when libcurl is used with other projects which also have a config.h.
+Yang Tse (29 Jul 2011)
+- cares-functions.m4 serial # bump
 
-Yang Tse (21 Jun 2009)
-- Refactor how libraries are checked for connect() function, follow-up.
+- Revert "configure: additional flag checks for fcntl() and socket()"
+  
+  This reverts commit 5f2a3b0e48f26d24cb1fefea0dccb92d417dcbf7.
 
-- Refactor how libraries are checked for connect() function,
-  and check for connect() as it is done for other functions.
+- configure: additional flag checks for fcntl() and socket()
 
-Gisle Vanem (20 Jun 2009)
-- Remove unneeded defines.
+- xc-translit.m4 fix quoting
 
-- Use select_s() and not select().
+- configure: avoid direct usage of AS_TR_* macros
 
-Yang Tse (19 Jun 2009)
-- sclose() function-like macro definition used to close a socket,
-  now solely based on HAVE_CLOSESOCKET and HAVE_CLOSESOCKET_CAMEL
-  config file preprocessor definitions.
+- xc-translit.m4 provides transliteration macros with well defined behavior.
 
-- add CloseSocket camel case function check
+Jakub Hrozek (15 Jun 2011)
+- Revert "Only fall back to AF_INET searches when looking for AF_UNSPEC addresses"
+  
+  This reverts commit b5823d65706af687c0e5110af8f0cfdcd068997d.
+  
+  This patch was not reviewed properly before pushing
 
-- check for socket() and closesocket() as it is done for other functions
+- Revert "Do not use sized constants in public headers"
+  
+  This reverts commit 22c01e96f7b2ae9923e1baa50bfe3c0d22297a7d.
+  
+  This is a Red Hat specific patch that does not belong into upstream
 
-- Remove HAVE_CONFIG_H definition from here,
-  CFLAGS from common.dj already defines it.
+- Use correct sizeof in ares_getnameinfo()
 
-- initial step towards decoupling c-ares from libcurl for DOS
+- Do not leak rr_name on failures inside ares_parse_ptr_reply
 
-- don't ignore these subdirs, they must be removed first
+- Do not leak rr_name on failures inside ares_parse_a_reply
 
-- Remove DEBUGBUILD symbol definition, is not required for programs using the library.
+- Do not leak rr_name on failures inside ares_parse_aaaa_reply
 
-- DEBUGBUILD symbol definition for debug builds
+- Do not leak rr_name on failures inside ares_parse_ns_reply
 
-- ignore some subdirs
+- Fix incorrect sizeof() in ares_save_options
 
-- fix comment
+- Fix incorrect allocation in ares_parse_ptr_reply()
 
-- Try to make more clear that --enable-curldebug has nothing to do with --enable-debug for this library.
+- Only fall back to AF_INET searches when looking for AF_UNSPEC addresses
 
-- Revert last change, it is inappropriate.
+- Do not use sized constants in public headers
 
-Gisle Vanem (12 Jun 2009)
-- Replace CURLDEBUG with DEBUGBUILD.
+Daniel Stenberg (13 Jun 2011)
+- [Jakub Hrozek brought this change]
 
-Yang Tse (11 Jun 2009)
-- when running automake copy missing files instead of symlinking them
+  ares_free_hostent(NULL) should be a noop
 
-- Adjusted to take in account that...
-  
-  With the curl memory tracking feature decoupled from the debug build feature,
-  CURLDEBUG and DEBUGBUILD preprocessor symbol definitions are used as follows:
-  
-  CURLDEBUG used for curl debug memory tracking specific code (--enable-curldebug)
-  
-  DEBUGBUILD used for debug enabled specific code (--enable-debug)
+Yang Tse (8 Jun 2011)
+- configure: fix recvfrom 5th arg type qualifier detection (followup)
 
-- c-ares' --enable-debug --enable-curldebug decoupling follow-up
+- configure: fix recvfrom 5th arg type qualifier detection
+  
+  Additionally remove whitespace from EOL
 
-- mention last changes
+Daniel Stenberg (4 Jun 2011)
+- strlen: use size_t to receive the return
 
-- Remove buildconf.bat from release and daily snapshot archives.
-  
-  buildconf.bat is only for CVS tree builds.
+Yang Tse (4 Jun 2011)
+- xlc: avoid preprocessor definition usage when linking
 
-- Ensure that buildconf.bat does nothing unless it is used with a CVS checkout.
+- ares_nowarn: icc 9.1 workaround
 
-- CVS-INFO file only present in CVS tree, never in release nor daily snapshot
-  archives. Used as a sentinel file in buildconf.bat to differentiate CVS builds.
+- ares_nowarn: header inclusion fix
 
-Gisle Vanem (8 Jun 2009)
-- Update comment about "ML". Removed "-D_USE_32BIT_TIME_T" (not a requirement).
+- ares_init: make ares_private.h last included header again
 
-Yang Tse (8 Jun 2009)
-- just comment it out
+- compiler warning: fix
+  
+  Fix compiler warning: conversion may lose significant bits
 
-- For debugging purposes...
+- compiler warning: fix
   
-  Disable the '-export-symbols-regex' to discard this as the origin
-  of link failures related with shared libraries and non-GNU linkers.
+  Fix compiler warning: variable was set but never used
+  
+  Fix compiler warning: clobber ignored
+
+- ares_iphlpapi: fix compiler warnings
+
+- winsock: compilation fixes
+  
+  Provide winsock iphlpapi alternative definitions to prevent compilation
+  failures when using a variety of winsock header implementations.
 
-- c-ares Makefile.am back to using $(top_builddir) for *_LDADD
+Daniel Stenberg (17 May 2011)
+- [David Stuart brought this change]
 
-- c-ares' -no-undefined and --enable-curldebug adjustments
+  IPv6-on-windows: find DNS servers correctly
 
-- Use relative path to built c-ares tree libtool library
+- man pages: docs for the c-ares utility programs
 
-- John E. Malmberg noticed that the configure script was failing to detect the
-  timeval struct on VMS when building with _XOPEN_SOURCE_EXTENDED undefined due
-  to definition taking place in socket.h instead of time.h
+- ares_parse_ns_reply.c: remove CVSism
 
-- Fix compiler warning: out of bound access
+Yang Tse (27 Mar 2011)
+- build: fix header inclusion
 
-- fix compilation on AIX
+- getservbyport replacement for Win CE
 
-- c-ares' --enable-curldebug adjustments
+- renamed getplatform() to ares__getplatform() to avoid namespace pollution
 
-- Remove temporarily introduced memory leak.
+- configure: fix libtool warning
+  
+  Recent versions of libtool are now tracing usage of AC_CONFIG_MACRO_DIR
+  macro and warn heavily when not used in configure script along with
+  ACLOCAL_AMFLAGS in Makefile.am.  So in order to make libtool happy
+  while keeping backwards compatibility this is added.
 
-- Temporarily introduce a memory leak to verify curl debug memory tracking works.
+- adig: RFC4034 resource record type detection
+  
+  Can be tested with: adig -s 8.8.8.8 -t ANY example.com
 
-- Allow curl debug memory tracking when building a shared library on
-  systems which support external, undefined, symbols in shared libraries.
+- nameser.h: RFC4034 resource record type definitions
 
-Daniel Stenberg (26 May 2009)
-- language fix
+- build: move platform stuff to ares_platform.c and ares_platform.h
 
-Yang Tse (26 May 2009)
-- Make ares_init(), ares_dup() and ares_init_options() return ARES_ENOTINITIALIZED
-  if library initialization has not been performed calling ares_library_init().
+- build: find out windows platform using GetVersionEx()
 
-- c-ares's --enable-curldebug configure option decoupled from c-ares's --enable-debug
+- build: use getenv() replacement function for systems which lack it
 
-- Prevent copying 'sourced' manpages for build targets that don't use them.
+- setup_once: system error codes for Windows CE
 
-Daniel Stenberg (23 May 2009)
-- minor edits
+- ares_search: use ERRNO macro for portability sake
 
-Yang Tse (21 May 2009)
-- Include .pdf versions of c-ares man pages in distribution tarball.
+- System's errno.h inclusion cleanup follow-up.
+  
+  System's errno.h is conditionally included from setup_once.h
 
-- Allow generation of .html and .pdf versions of c-ares man pages.
+- Windows CE specific adjustment
+  
+  All versions of Windows CE support Winsock 1.1
 
-Gisle Vanem (21 May 2009)
-- $(OBJ_DIR)/ares_getopt.o must be cleaned explicitly.
+- System's errno.h inclusion cleanup.
+  
+  System's errno.h is conditionally included from setup_once.h
 
-Yang Tse (20 May 2009)
-- Mention last changes
+- ares_init: fix gethostname error detection on winsock platforms
 
-- Initial ares_library_cleanup(3) man page
+- configure: r-enable temporarily disabled detection of system's inet_ntop()
+  
+  Detection was temporarily disabled in commit 674e044ccb21f2f63537da53565fce868f
 
-- Update man page
+Daniel Stenberg (15 Mar 2011)
+- configure: stop using the deprecated AM_INIT_AUTOMAKE syntax
 
-- Update man page
+- [Gisle Vanem brought this change]
 
-- Initial ares_library_init(3) man page attempt
+  Watt-32: use errno
+  
+  Make sure Watt-32 programs use 'errno' even on Win32 targets
 
-- Force revision update, to force CVS to update the $Id date string format
+Guenter Knauf (18 Feb 2011)
+- Removed commented CLFAGS no longer needed.
 
-- Add same copyright notice as other c-ares files
+- Fixed CFLAGS for NetWare.
+  
+  Added -m32 to enable compilation with x86_64 compilers;
+  added conditional to set -fpcc-struct-return only for gcc compiler.
 
-- Fix case
+Daniel Stenberg (18 Feb 2011)
+- [Gisle Vanem brought this change]
 
-- Remove run-time requirement for advapi32.dll since
-  c-ares can work even with no advapi32.dll at all.
+  Watt32: fix server init
+  
+  Somewhere in the process, programs using the Watt-32 tcp/ip stack
+  stopped working.
 
-- Intentionally avoid checking if the address of SystemFunction036, a.k.a.
-  RtlGenRandom, has been located or not. This function is only available on
-  WinXP and later. When unavailable c-ares uses portable rand() function.
+- [Dima Tisnek brought this change]
 
-- - Provide in external interface preprocessor symbol definitions for
-    CARES_HAVE_ARES_LIBRARY_INIT and CARES_HAVE_ARES_LIBRARY_CLEANUP
-    to ease the use of new capabilities.
+  config_sortlist: (win32) missing else
   
-  - Move ares_version() prototype to ares.h
+  Without an else there, contents of "pat" that could have been
+  successfully set just above, may be clobbered by successive unsuccessful
+  calls to "xxx_pton" or "ip_addr".
 
-- Introduction of ares_library_init() and ares_library_cleanup()
+Yang Tse (17 Jan 2011)
+- Makefile.msvc: add a couple of VS version strings
+
+- Makefile.msvc: add a couple of VS version strings
 
-- Introduction of ares_library_init() and ares_library_cleanup()
+- build: add install target to Makefile.msvc
 
-- remove outdated comment
+Daniel Stenberg (27 Dec 2010)
+- ares_set_servers_csv: remove unused variables
 
-- Fix preprocessor conditional expression
+- init_by_resolv_conf: fix compiler warnings
+  
+  The code received the return codes in the 'status' variable without
+  using it. Instead we just ignore those particular errors.
 
-- fiX *__SOCKLEN_T definitions for remaining targets
+- getv4: Value stored to 'dst' is never read
 
-- *__SOCKLEN_T definitions for OS400 already fixed
+- advance_tcp_send_queue: avoid NULL ptr dereference
+  
+  If given a too large 'num_bytes' value, it would cause a NULL ptr
+  dereference. Instead the code will now break out of the loop at the end
+  of the list.
 
-- fIX *__SOCKLEN_T definitions for SYMBIAN32 and VMS targets
+- [Peter Pentchev brought this change]
 
-Daniel Stenberg (11 May 2009)
-- - Gregor Jasny made c-ares link with libtool 's -export-symbols-regex option to
-    only expose functions starting with ares_.
+  configure: fix a bashism
 
-Yang Tse (11 May 2009)
-- Remove experimental check. Currently there's no need for it.
+- cleanup: avoid unsafe typecasts
+  
+  Avoid the risk of reading 16bit data from an unaligned address by using
+  a macro that is adapted for this.
 
-- Fix an m4 overquoting triggering a spurious 'AS_TR_CPP' symbol definition
-  attempt in generated config.h
+- [Stefan Bühler brought this change]
 
-- Proper naming for the experimental compiler test and moved to *-compilers.m4
+  ares_expand_name: Fix encoded length for indirect root
 
-- Moved *_CHECK_COMPILER_HALT_ON_ERROR and *_CHECK_COMPILER_ARRAY_SIZE_NEGATIVE to *-compilers.m4 along with other *_CHECK_COMPILER_*
+Yang Tse (18 Dec 2010)
+- build: add some explicit file references to VS project files
 
-- fIX *__SOCKLEN_T definitions for OS400 and generic GCC targets
+- config-win32: provide HAVE_ASSERT_H definition
 
-- fIX *__SOCKLEN_T definitions for MVS and 370 targets
+- build: include ares_nowarn in sample program VS project files
 
-- fIX *__SOCKLEN_T definitions for several Windows target tool-chains
+- build: include ares_nowarn among SAMPLESOURCES and SAMPLEHEADERS
 
-- HP-UX's X/Open network library requirement check follow-up
+- configure: temporarily disable detection of system's inet_ntop()
+  
+  This is done to allow compilation of ares_inet_ntop() by some daily
+  builds picky compilers that otherwise do not need this function.
 
-- HP-UX's X/Open network library requirement check follow-up
+- changes: mention last fix
 
-- Use build-time configured ares_socklen_t instead of socklen_t
+- ares_inet_ntop: remove definition and usage of macro SPRINTF
+  
+  Existing definition of SPRINTF always resulted in sprintf() being used,
+  and sprintf() returning 'int' is already used throughout the library.
 
-- David McCreedy's "TPF-platform specific changes to various files" patch follow-up
+- ares_inet_ntop: reapply changes from previous c-ares version (III)
+  
+  - Replace 'u_char' with 'unsigned char'.
+  - Replace 'u_int' with 'unsigned int'.
+  - use macros ERRNO and SET_ERRNO() for errno handling.
 
-Daniel Stenberg (1 May 2009)
-- s/libcurl/c-ares
+- ares_inet_ntop: reapply changes from previous c-ares version (II)
+  
+  - Remove rcsid.
+  - Adjust header file inclusions.
+  - ares_inet_ntop used only on systems without a proper inet_ntop function.
 
-- version number typo fix
+- ares_inet_ntop: reapply changes from previous c-ares version (I)
+  
+  - Replace tabs with spaces.
+  - Use ANSI C style for function declarations and definitions.
+  - Use sizeof with parentheses.
 
-Yang Tse (1 May 2009)
-- David McCreedy's "TPF-platform specific changes to various files" patch
+- ares_inet_ntop: fix off by one error triggering out of bounds write
+  
+  ares_inet_ntop would trigger an out of bounds write when the representation
+  of the address required 15 characters, due to not taking in account null
+  termination character.
+  
+  Full import of inet_ntop.c from bind-9.5.3rc1 to pull additional fixes.
 
-- Check definition of _XOPEN_SOURCE_EXTENDED with the compiler
+- ares_nowarn: add conditional inclusion of assert.h header
 
-- Check if X/Open network library is required
+- fix compiler warning: conversion may lose significant bits
 
-- cope with ares_build.h and ares_rules.h follow-up
+- ares_inet_net_pton: fix non-rejection of some malformed literals
+  
+  ares_inet_net_pton would return wrong values when excessively large,
+  and invalid, netmasks are used. Fixes are from bind-9.5.3rc1,
+  issue also described in the WLB-2008080064 advisory.
 
-- Added some notes regarding ares_build.h
+- setup_once: provide ISASCII macro
 
-- fix EOL
+- configure: inet_net_pton function check adjustments
+  
+  Define HAVE_INET_NET_PTON only when system's inet_net_pton function is IPv6
+  capable and is not affected by the WLB-2008080064 advisory.
+  
+  HAVE_INET_NET_PTON_IPV6 is no longer defined nor used.
 
-- fix EOL
+- ares_init: fix detection of semicolon comments in resolv.conf
+  
+  File resolv.conf may either use a hash '#' or a semicolon ';' character as an
+  indication that the rest of the line is a comment.  This fixes not recognizing
+  the semicolon as a valid comment indicator in resolv.conf.
 
-- cope with ares_build.h and ares_rules.h
+- version: start working on 1.7.5
 
-- buildconf.bat for CVS-tree c-ares
+Version 1.7.4 (8 Dec 2010)
 
-- Use 'unsigned int' instead of size_t attempting to avoid header inclusion
+Daniel Stenberg (8 Dec 2010)
+- release-preps: CHANGES and RELEASE-NOTES synced
 
-- NetWare LibC's getpeername() third argument data type is size_t
+- ares_set_local_*: added in 1.7.4, not before
 
-- Remove temporary debug tracing for ares_socklen_t Windows targets
+Yang Tse (3 Dec 2010)
+- build: provide SIZEOF_SIZE_T definition for non-configure builds
 
-- ares_socklen_t follow-up
+- build: config.dos renamed to config-dos.h
 
-- ares_build.h Windows follow-up
+- build: provide SIZEOF_SIZE_T netware definition
 
-- Add temporary debug tracing for ares_socklen_t Windows targets
+- ares_gethostbyaddr: fix compiler warning: conversion may lose significant bits
 
-- ares_build.h NetWare follow-up
+- configure: undo using autobuilds to temporarily verify strict aliasing warnings.
 
-- ares_build.h NetWare attempt
+- fix compiler warning: rounding, sign extension, or loss of accuracy may result
 
-- Initial step towards a configure time ares_socklen_t definition
+Daniel Stenberg (2 Dec 2010)
+- [Ben Noordhuis brought this change]
 
-- ignore stamp-h*
+  ares_parse_a_reply: fix CNAME response parsing
+  
+  Reply to a CNAME query doesn't contain addresses, causing
+  ares_parse_a_reply() to bail out with ARES_ENODATA
+  
+  Bug: http://groups.google.com/group/nodejs/browse_thread/thread/a1268c9ea5e9ad9b
 
-- Added CARES_INCLUDES_SYS_TYPES
+Yang Tse (1 Dec 2010)
+- fix compiler warning: conversion may lose significant bits
 
-- Initial step towards a configure time curl_socklen_t definition
+- atoi: remove atoi usage
 
-- avoid use of alloca()
+- ares_init: fix compiler warning: conversion may lose significant bits
 
-- Moved potential inclusion of system's malloc.h and memory.h header files to
-  setup_once.h.  Inclusion of each header file is based on the definition of
-  NEED_MALLOC_H and NEED_MEMORY_H respectively.
+- configure: fix autoconf warning
 
-- ignore
+- inet_pton: fix compiler warning
 
-Gisle Vanem (18 Apr 2009)
-- Added '-DHAVE_LIMITS_H'.
+- configure: use autobuilds to temporarily verify strict aliasing warnings.
+  
+  Temporarily, When cross-compiling with gcc 3.0 or later, enable strict aliasing
+  rules and warnings. Given that cross-compiled targets autobuilds do not run the
+  test-suite, there is no risk of running code that violates strict aliasing rules
 
-Yang Tse (17 Apr 2009)
-- remove compiler options used while debugging the icc 9.1 optimizer issue
+- ares_getnameinfo: Partially revert commit 85520d66e0ac7ac73411bc25e98769a88b2f
+  
+  Upon socket address family and length validation failure return ARES_ENOTIMP
+  in callback again, this is the error code documented in man page and used
+  mostly all over the library.
 
-- moved HAVE_LIMITS_H to common defines
+- ares_getnameinfo: Validate socket address family and length.
+  
+  Validate socket address family and that the socket address length is appropriate
+  for the specified family. Failure is reported with ARES_EBADFAMILY in callback.
 
-- Set HP-UX compiler warning level back to the one that exposes
-  the socklen_t issue on this platform.
+- ares_getnameinfo: fix two compiler warnings
 
-- HAVE_LIMITS_H definition for NetWare CLIB
+- Added another VS10 version string
 
-- use HAVE_LIMITS_H symbol to protect limits.h inclusion
+- Fix GCC 4 compiler warning 'dereferencing type-punned pointer might break strict-aliasing rules'.
 
-- fix compiler warning: implicit conversion shortens 64-bit value into a 32-bit value
+- Revert commit 494274e653936335c255a47599970de3df21e7c4
 
-- s/u_long/unsigned long/
+- configure: fix autoconf 2.68 warning: no AC_LANG_SOURCE call detected in body
 
-- Do not halt compilation when using VS2008 to build a Windows 2000 target
+- Fix compiler warning: array subscript has type 'char'
 
-- ignore
+- Fix GCC 4 compiler warning 'dereferencing type-punned pointer might break strict-aliasing rules'.
 
-Phil Blundell (3 Feb 2009)
-- * February 3 2009 (Phil Blundell)
-  - If the server returns garbage or nothing at all in response to an AAAA query,
-    go on and ask for A records anyway.
+- Revert following commits:
+    07bc7ea79509bcc9ef6e09151e81766ed00d3392
+    3392a50ea3f8573ea4b7a9d82b9833dab60cb0e9
+    9912637d32c9987719a1ea12db591aee2941891c
+  
+  The purpose of the whole patch was to silence a compiler warning triggered
+  with GCC 4 on file ares_process.c  The specific compiler warning was
+  'dereferencing type-punned pointer might break strict-aliasing rules'.
+  
+  A simpler patch will follow to equally silence the warning.
 
-Daniel Stenberg (31 Jan 2009)
-- - ares_gethostbyname() now accepts 'AF_UNSPEC' as a family for resolving
-    either AF_INET6 or AF_INET. It works by accepting any of the looksups in the
-    hosts file, and it resolves the AAAA field with a fallback to A.
+- ares_options: reorder header inclusions to make inclusion of
+  ares_private.h the last included one again.
 
-Gisle Vanem (18 Jan 2009)
-- fopen() returns error in 'errno' even on Windows.
-  So don't use ERRNO (GetLastError()). Trimmed trailing
-  blanks.
+Daniel Stenberg (12 Nov 2010)
+- [Patrik Thunstrom brought this change]
 
-- Constified some arguments in local functions.
+  adig: fix NAPTR parsing
+  
+  I ran across a small "issue" in your adig example.
+  
+  It is simply the last part of the NAPTR record, the replacement element,
+  which is not a string, as currently handled in adig, but a domain name.
 
-Daniel Stenberg (14 Jan 2009)
-- - ares.h no longer uses the HAVE_STRUCT_IN6_ADDR define check, but instead it
-    now declares the private struct ares_in6_addr for all systems instead of
-    relying on one possibly not present in the system.
+- ares_save_options: assignments instead of memcpy
 
-Phil Blundell (13 Jan 2009)
-- - ares__send_query() now varies the retry timeout pseudo-randomly to avoid
-    packet storms when several queries were started at the same time.
+- init_by_options: don't copy an empty sortlist
+  
+  If there aren't any sort items to copy, don't bother. Without this
+  little precaution it would do a malloc(0) which causes undefined
+  behaviors and is frowned upon by curl's memdebug-system.
 
-Daniel Stenberg (11 Jan 2009)
-- - Phil Blundell added the internal function ares__expand_name_for_response()
-    that is now used by the ares_parse_*_reply() functions instead of the
-    ares_expand_name() simply to easier return ARES_EBADRESP for the cases where
-    the name expansion fails as in responses that really isn't expected.
+Guenter Knauf (3 Oct 2010)
+- Minor Watcom makefile tweaks.
 
-Gunter Knauf (30 Dec 2008)
-- added HAVE_SOCKADDR_IN6_SIN6_SCOPE_ID to ares Makefile.netware and sync'd with other Makefile.netware.
+Daniel Stenberg (30 Sep 2010)
+- [Mike Crowe brought this change]
 
-Daniel Stenberg (9 Dec 2008)
-- use the new URL
+  Fix lookup with HOSTALIASES set.
+  
+  ares__read_line returns ARES_EOF when it reaches the end of the
+  file. This will happen every time when reading to the end of the
+  HOSTALIASES file. Unfortunately single_domain treats this error as
+  being fatal.
+  
+  Signed-off-by: Mike Crowe <mac@mcrowe.com>
 
-- start over on the 1.6.1 release...
+Ben Greear (24 Aug 2010)
+- Add missing break that caused get_ares_servers to fail.
+  
+  Reported-by: Ning Dong <flintning@163.com>
+  Signed-off-by: Ben Greear <greearb@candelatech.com>
 
-Version 1.6.0 (9 Dec 2008)
+Yang Tse (11 Aug 2010)
+- configure: werror related adjustments
 
-Daniel Stenberg (9 Dec 2008)
-- add space
+Guenter Knauf (8 Aug 2010)
+- Added copyright string to ares_version.h and make use of it in other files.
 
-Gisle Vanem (9 Dec 2008)
-- Fix for Win32 targets using Watt-32.
+- Block created ares_build.h for NetWare to avoid usage from other platforms.
 
-Dan Fandrich (9 Dec 2008)
-- C89 compilers (like Minix' ACK) only need to handle 31 functions arguments
-  so split a long sprintf into two calls to get below that number.
+- Fix to overwrite default libname.
 
-Gisle Vanem (8 Dec 2008)
-- Added needed defines for Watt-32 on Windows.
+- Some more Watcom makefile massage ...
 
-- Undefine 'optarg', 'optind' and 'opterr' when using Watt-32
-  (to get correct linkage on Windows).
+- Some more Watcom makefile massage ...
 
-- ares_writev() shall not be exported when using Watt-32 (has writev).
-  Added _USE_32BIT_TIME_T to avoid runtime warning. Applies to
-  VC-2008+ only.
+Ben Greear (4 Aug 2010)
+- sock-addr-storage:  Detect and deal with lack of .ss_family member.
+  
+  AIX, at least, does not have sockaddr_storage.ss_family member.
+  Detect this in the configure logic and use proper #ifdefs in the
+  ares_process logic.
+  
+  Signed-off-by: Ben Greear <greearb@candelatech.com>
+  Tested-by: Tor Arntsen <tor@spacetec.no>
 
-- Removed unneeded defines HAVE_SIGNAL_H, HAVE_SIG_ATOMIC_T,
-  RETSIGTYPE and HAVE_PROCESS_H.
+Guenter Knauf (3 Aug 2010)
+- Added Watcom makefile based on libcurl's Makefile.Watcom.
 
-Daniel Stenberg (4 Dec 2008)
-- the initial version of the ares_set_socket_callback man page
+Ben Greear (31 Jul 2010)
+- typo:  Fix compile bug for platforms that don't have sockaddr_storage.
+  
+  Bug was introduced by me in previous commit.
+  
+  Signed-off-by: Ben Greear <greearb@candelatech.com>
 
-- Gregor Jasny provided the patch that introduces ares_set_socket_callback(),
-  and I edited it to also get duped by ares_dup().
+- Fix aliasing warning in gcc 4.4.4 (at least).
+  
+  Should be no functional change, though the code gets a bit
+  ugglier.
+  
+  Signed-off-by: Ben Greear <greearb@candelatech.com>
 
-Dan Fandrich (4 Dec 2008)
-- Bring the sys/include.h include test in line with curl's.
+Daniel Stenberg (31 Jul 2010)
+- ares_set_servers_csv: use ISDIGIT
+  
+  The IS*() set of macros are preferred to the regular is*() functions as
+  they help us avoid the most common pitfalls.
 
-Daniel Stenberg (3 Dec 2008)
-- Let's not call ares_save_options() deprecated just yet
+Ben Greear (30 Jul 2010)
+- cast arg to isdigit to int
+  
+  Looks like it might silence a warning on Netware build.
+  
+  Signed-off-by: Ben Greear <greearb@candelatech.com>
 
-- Introduce ares_dup(3) and new thoughts about API/ABI and how to move forwards.
-  Also discussed on the ml.
+- remove all uses of uint32_t
+  
+  Previous fix forgot a few.
+  
+  Signed-off-by: Ben Greear <greearb@candelatech.com>
 
-Dan Fandrich (2 Dec 2008)
-- Make sure sys/socket.h is included before netinet/in.h (required by
-  OpenWatcom C, and condoned by SUS)
+- fix signed v/s unsigned casts warning in ares_gethostbyaddr.c
+  
+  Signed-off-by: Ben Greear <greearb@candelatech.com>
 
-Daniel Stenberg (1 Dec 2008)
-- minor indent fix
+- local-bind-fixup:  Fix inet_pton warning.
+  
+  Conditionally include <arpa/inet.h> for inet_pton
+  headers.
+  
+  Signed-off-by: Ben Greear <greearb@candelatech.com>
 
-- Convert the public config struct to the same binary size/construct as in the
-  latest releases to remain ABI compatible.
+- build:  Enable compiling with -Werror.
+  
+  This helps find compile warnings because they simply break
+  the build.
+  
+  To use:
+  ./configure --enable-warnings --enable-werror
+  
+  Signed-off-by: Ben Greear <greearb@candelatech.com>
 
-Gisle Vanem (29 Nov 2008)
-- Added '-DHAVE_GETHOSTNAME'.
+- ipv6: Fix some build issues related to the local-bind feature.
+  
+  Signed-off-by: Ben Greear <greearb@candelatech.com>
 
-Dan Fandrich (29 Nov 2008)
-- Make sure sys/socket.h is included before netinet/in.h (required by
-  OpenWatcom C)
+Guenter Knauf (29 Jul 2010)
+- Replaced uint32_t with unsigned int to fix broken builds on a couple of platforms.
 
-- Netware has gethostname()
+Daniel Stenberg (18 Jul 2010)
+- [Ben Greear brought this change]
 
-- Fixed a couple of typos
+  local-bind:  Support binding to local interface/IPs
+  
+  Add 3 new functions to set the local binding for the out-going
+  socket connection, and add ares_set_servers_csv() to set a
+  list of servers at once as a comma-separated string.
+  
+  Signed-off-by: Ben Greear <greearb@candelatech.com>
 
-- Don't tweak the HAVE_* macros when using autoconf
+- version: now start on 1.7.4
 
-- Make use of gethostname() conditional on it being available
+- [Andrew C. Morrow brought this change]
 
-- Only set TCP_NODELAY when it exists
+  fix memory leak in ares_getnameinfo
 
-Daniel Stenberg (28 Nov 2008)
-- updated with changes, preparing for a release soon
+Version 1.7.3 (11 Jun 2010)
 
-Yang Tse (26 Nov 2008)
-- Gerald Combs fixed a bug in ares_parse_ptr_reply() which would cause a
-  buffer to shrink instead of expand if a reply contained 8 or more records.
+Daniel Stenberg (11 Jun 2010)
+- changelogs: updated for 1.7.3
 
-- Brad Spencer provided changes to allow buildconf to work on OS X.
+- [BogDan Vatra brought this change]
 
-- In preparation for the upcomming IPv6 nameservers patch, the internal
-  ares_addr union is now changed into an internal struct which also holds
-  the address family.
+  init: allow c-ares to work on Android OS
 
-Dan Fandrich (20 Nov 2008)
-- Make checking for struct ifreq a prerequisite for setting
-  HAVE_IOCTL_SIOCGIFADDR since it's needed to use SIOCGIFADDR and Watcom C
-  doesn't currently define it.
+- changelog: fill in the 1.7.2 changes
 
-Daniel Stenberg (20 Nov 2008)
-- use unsigned short better intead of mixing with ints to prevent compiler
-  warnings
+- added another pdf to ignore
 
-- please the picky compilers by staying with short as the data we get is short
-  only
+Yang Tse (11 Jun 2010)
+- add ares_parse_mx_reply.c to VS dsp file
 
-- - Brad Spencer brought the new function ares_gethostbyname_file() which simply
-    resolves a host name from the given file, using the regular hosts syntax.
+Daniel Stenberg (10 Jun 2010)
+- tarball: add $(CSOURCES) $(HHEADERS) to EXTRA_DIST
+  
+  It's not clear to me why we need this, but we apparently may
+  otherwise not get all files bundled in the dist tarball.
 
-Yang Tse (19 Nov 2008)
-- user provided PATH_SEPARATOR always overrides auto-detected one
+- version: start working on 1.7.3
 
-- attempting to keep lines below 80 chars
+Version 1.7.2 (10 Jun 2010)
 
-- provide a common PATH_SEPARATOR check method which is required by
-  upcomming work to support the broadest range of Autoconf versions
+Daniel Stenberg (10 Jun 2010)
+- RELEASE-NOTES: 1.7.2 details added
 
-- check for gethostbyaddr and gethostbyname as it is done for other functions
+- [Jakub Hrozek brought this change]
 
-- Make configure script check if ioctl with the SIOCGIFADDR command can be
-  used, and define HAVE_IOCTL_SIOCGIFADDR if appropriate.
+  ares_init: Last, not first instance of domain or search should win
 
-- fix leftover from previous commit
+- style: make code less than 80 columns wide
 
-- fix inet_pton() runtime configure check
+Yang Tse (31 May 2010)
+- [Tor Arntsen brought this change]
 
-- trim down configure script size
+  improve alternative definition of bool to use enum instead of unsigned char
 
-Daniel Stenberg (15 Nov 2008)
-- Fixed an OOM condition reported by Jim Meyering
+- fix VS2010 compiler warnings
 
-Yang Tse (14 Nov 2008)
-- fix typo affecting inclusion of <arpa/inet.h> in configure
-  checks for inet_ntoa_r() inet_ntop() and inet_pton()
+Daniel Stenberg (18 Apr 2010)
+- [Jérémy Lal brought this change]
 
-- #include <string.h> in the getaddrinfo() runtime check for the memset() prototype
+  added ares_parse_mx_reply
 
-- fix symbol definition check for fcntl.h inclusion
+- repair the file mode
 
-- Refactor configure script detection of functions used to set sockets into
-  non-blocking mode, and decouple function detection from function capability.
+- remove all $Id$ lines
 
-Daniel Stenberg (1 Nov 2008)
-- Added a TODO file to list things we want changed, added or fixed.
+- remove all .cvsignore files
 
-- - Carlo Contavalli added support for the glibc "rotate" option, as documented
-    in man resolv.conf:
-  
-    causes round robin selection of nameservers from among those listed.  This
-    has the effect of spreading the query load among all listed servers, rather
-    than having all clients try the first listed server first every time.
+- spell fix
   
-    You can enable it with ARES_OPT_ROTATE
-
-Yang Tse (1 Nov 2008)
-- Adjust WIN32 freeaddrinfo, getaddrinfo and getnameinfo availability
-
-- WIN32 availability of freeaddrinfo, getaddrinfo and getnameinfo functions is quite
-  convoluted, compiler dependant and in some cases even build target dependat.
-
-- check for freeaddrinfo() at configuration phase
-
-- update aclocal file serial number
-
-- remove verification of the freeability of the addrinfo struct pointer members
+  reported by Gregor Jasny on the mailing list
 
-- fix comment
+- [Peter Pentchev brought this change]
 
-- make CHECK_FUNC_GETADDRINFO_UNFREEABLE_AI_ADDR
-   and CHECK_FUNC_GETADDRINFO_UNFREEABLE_AI_CANONNAME
-  internal to CHECK_FUNC_GETADDRINFO
+  Fix a couple of typos and grammar nits.
 
-- fix leftover
+- ignore the GPG signature files too
 
-- Initial attempt to detect at configuration time if the getaddrinfo()
-  function returns an addrinfo with an unfreeable ai_canonname member ptr.
+- start the journey towards 1.7.2
 
-- Initial attempt to detect at configuration time if the getaddrinfo()
-  function returns an addrinfo with an unfreeable ai_addr member ptr.
+- no longer CVS tagging
 
-- icc adjustments:
-  
-    Select ANSI C89 dialect plus GNU extensions, again.
+- ignore generated PDFs
 
-- some more temporary magic for the icc seg-fault issue
+Version 1.7.1 (23 Mar 2010)
 
-- icc permanent adjustment:
-  
-    Select precise floating-point model, otherwise doubles are less than 64-bit wide
-  
-  icc test adjustment:
-  
-    Select c89 dialect
+Daniel Stenberg (23 Mar 2010)
+- 1.7.1
 
-- icc adjustments:
-  
-    Enable more icc warnings.
+- made README the primary readme file
   
-    Optimization disabling options used only for icc 9.1
+  ... and did README.cares to contain a historic reason etc.
 
-- #include <stdlib.h> for exit() prototype
+- s/CVS/git
 
-- some more temporary magic for the icc seg-fault issue
+- git now, not CVS
 
-- remove from configure.ac temporary magic for the icc seg-fault issue
+- ignore lots of generated files
 
-- some more temporary magic for the icc seg-fault issue
+- [Daniel Johnson brought this change]
 
-- Charles Hardin patch:
-  
-  - handles the EINPROGRESS for UDP connects
-  - uses closesocket instead of close on some paths that were noticed
+  Fix warnings for clang
 
-- some more temporary magic for the icc seg-fault issue
+Yang Tse (17 Mar 2010)
+- replaced intel compiler option -no-ansi-alias with -fno-strict-aliasing
 
-- messages initially intended only for debug purposes, now become permanent
-  since these are extremely useful when compiler rejects a set of options.
+- update outdated serial number
 
 - fix compiler warning
 
-- fix missing double-quotes
-
-Daniel Stenberg (17 Oct 2008)
-- Charles Hardin made adig support a regular numerical dotted IP address for the
-  -s option as well.
-
-Yang Tse (16 Oct 2008)
-- some more temporary magic for the icc seg-fault issue
-
-- Ensure that shell variable contents which have active meaning
-  to the shell echo command are not interpreted when trying to
-  remove extra whitespace from shell variable content.
+- watt32 compilation fix
 
-- Adjust Watcom C warnings:
-  
-    Disable warnings on structure members padding.
+- Added another VS10 version string
 
-- With this change Solaris target builds will now be done with _REENTRANT defined.
+- fix line break
 
-- Adjust Tiny C basic options:
-  
-    Remove -b from debug-enabled configuration, as Tiny C might have
-    been built without the memory and bounds checker support.
+- removed usage of 's6_addr', fixing compilation issue triggered with no
+  longer using 'in6_addr' but only our 'ares_in6_addr' struct
 
-- Adjust GCC warnings:
-  
-    Better disable following warnings when cross-compiling with a gcc older
-    than 3.0, to avoid warnings from third party system headers:
-  
-      -Wmissing-declarations
-      -Wmissing-prototypes
-      -Wunused
-      -Wshadow
+Daniel Stenberg (5 Mar 2010)
+- Daniel Johnson provided fixes for building with the clang compiler
 
-- fix syntax error
+Yang Tse (5 Mar 2010)
+- Added IPv6 name servers support
 
-- Initial attempt to detect Watcom C compiler
+Gisle Vanem (5 Mar 2010)
+- Ops!. Readded ares_nowarn.h.
 
-- make naming scheme more consistent across whole file
+- Added ares_nowarn.c.
 
-- Adjust GCC warnings:
-  
-    Disable following warnings when cross-compiling with a gcc older
-    than 3.0, to avoid warnings from third party system headers:
-  
-      -Wmissing-prototypes
-      -Wunused
-      -Wshadow
+Yang Tse (28 Feb 2010)
+- Added SIZEOF_INT and SIZEOF_SHORT definitions for non-configure systems
 
-- Adjust GCC --enable-warnings:
-  
-    Do not enable -pedantic when cross-compiling with a gcc older
-    than 3.0, to avoid warnings from third party system headers.
+- Added ares_nowarn.* to VC6 project file
 
-- adjust SGI MIPSpro C detection
+- Added SIZEOF_INT definition
 
-- LCC compiler adjustments:
-  
-    Highest warning level is double -A, next is single -A.
-    Due to the big number of warnings these trigger on third
-    party header files it is impratical for us to use any of
-    them here. If you want them simply define it in CPPFLAGS.
+- fix compiler warning
 
-- remove extra space
+- fix compiler warning
 
-- split SGI compiler check. One for MIPS C and another for MIPSpro C
+- fix compiler warning
 
-- LCC compiler adjustments:
+Daniel Stenberg (17 Feb 2010)
+- ares_reinit()
   
-    Warning level reduced from double -A to single -A
+  - To allow an app to force a re-read of /etc/resolv.conf etc, pretty much
+    like the res_init() resolver function offers
 
-- Initial attempt to detect Tiny C compiler
+- - Tommie Gannert pointed out a silly bug in ares_process_fd() since it didn't
+    check for broken connections like ares_process() did. Based on that, I
+    merged the two functions into a single generic one with two front-ends.
 
-- Initial attempt to detect LCC compiler
+Yang Tse (30 Dec 2009)
+- VMS specific preprocessor symbol checking adjustments
 
-- 1) fix bug in CONVERT_INCLUDE_TO_ISYSTEM
-  
-  2) Disable SGI remark: controlling expression is constant
+- Mention last changes
 
-- simplify SGI C compiler check
+- - Fix configure_socket() to use ares_socket_t instead of int data type.
 
-- HP C adjustments:
-  
-    Due to the HP-UX socklen_t issue it is insane to use the +w1 warning level.
-    It generates more than 1100 warnings on socklen_t related statements.
+- - Where run-time error checks enabling compiler option /GZ was used it is now
+    replaced with equivalent /RTCsu for Visual Studio 2003 and newer versions.
   
-    Until the issue is somehow fixed we will just use the +w2 warning level.
-
-- Add debug tracing for COMPILER_WORKS_IFELSE
+  - Compiler option /GX is now replaced with equivalent /EHsc for all versions.
 
-- configure will also warn on 'strict compiler warning' rejected options
+- - Ingmar Runge noticed that Windows config-win32.h configuration file
+    did not include a definition for HAVE_CLOSESOCKET which resulted in
+    function close() being inappropriately used to close sockets.
 
-- convert rejected compiler options messages into a warnings
+Daniel Stenberg (30 Nov 2009)
+- start working on 1.7.1
 
-- remove extra whitespace from string in SGI C check
+Version 1.7.0 (27 Nov 2009)
 
-- oops
+Yang Tse (27 Nov 2009)
+- Preserve empty line following last target
 
-- Initial attempt to detect SGI C compiler
+- - Larry Lansing fixed ares_parse_srv_reply to properly parse replies
+    which might contain non-SRV answers, skipping over potential non-SRV
+    ones such as CNAMEs.
 
-- HP C adjustments:
-  
-    Disallow run-time dereferencing of null pointers.
-  
-    Disable some remarks:
-  
-      #4227: padding struct with n bytes to align member.
-  
-      #4255: padding size of struct with n bytes to alignment boundary.
+- When using icc, compile with -fpic and link with intel dynamic libraries.
 
-- improve presentation of accepted/rejected debug/optimizer options
+- Added 'currently' in italics to insist on transient situation.
 
-- refactoring of COMPILER_BASIC_OPTS
+- Fix language
 
-- Initial attempt to detect SUN C compiler
+- Daniel wants upcoming release to be 1.7.0
 
-- Initial attempt to detect HP C compiler
+- Mention last changes
 
-- fix compiler warning: 'dot_4' may be used uninitialized in this function
+- - Removed from external interface preprocessor symbol definition for
+    CARES_HAVE_ARES_FREE_DATA. Current functionality of ares_free_data()
+    makes it unnecessary.
 
-- adjust ICC_windows settings
+- Added README.msvc
 
-- fix VAR_STRIP
+- Changed c-ares naming conventions when using MSVC as described in README.msvc
 
-- Sync up with reality
+- - Mention other recent changes
 
-- Initial attempt to support configure's --(dis|en)able-optimize
-  option to specify dis(activation) of compiler optimizations.
-  
-  If option is specified, it will be honored independant of the
-  --(dis|en)able-debug option.
+- - Jakub Hrozek renamed addrttl and addr6ttl structs to ares_addrttl and
+    ares_addr6ttl in order to prevent name space pollution, along with
+    necessary changes to code base and man pages.This change does not break
+    ABI, there is no need to recompile existing applications. But existing
+    applications using these structs with the old name will need source code
+    adjustments when recompiled using c-ares 1.6.1.
 
-- fix comment
+- - Jakub Hrozek fixed more function prototypes in man pages to sync them
+    with the ones declared in ares.h
 
-- Initial attempt to support configure's --(dis|en)able-warnings
-  option to specify dis(activation) of picky compiler warnings.
-  
-  If option is specified, it will be honored independant of the
-  --(dis|en)able-debug option.
-  
-  If option is not specified, it will follow --(dis|en)able-debug
-  setting, whose default is disabled if not specified.
+- Make configure remove the ares_build.h file included in distribution tarballs.
 
-- fix compiler warning: dereferencing type-punned pointer will break strict-aliasing rules
+- Fix macro redefinition.
 
-- now compiler warnings are activated for all gcc builds, not only debug ones.
+- Fix name space pollution.
 
-- Use CFLAGS for icc linker options instead of LDFLAGS,
-  otherwise gethostbyname() is not detected.
+- Allow using different extra import libraries for debug and release builds.
 
-- use ac_cv_compiler and ac_cv_compiler_num to keep compiler ID and version number
+- Add manifest stuff to msvc makefile
 
-- Temporary icc adjustment:
-  
-    Disable floating point optimizations
+- Sync man page with reality
 
-- HAVE_INET_PTON will only be defined when an IPv6 capable working
-  inet_pton function is available.
+- Add missing external API decoration for ares_set_socket_callback()
 
-- HAVE_INET_NTOP will only be defined when an IPv6 capable working
-  inet_ntop function is available.
+- Add ares_free_data() man page.
 
-- ntoa() and inet_ntoa_r() no longer used
+- - Provide in external interface preprocessor symbol definitions for
+    CARES_HAVE_ARES_FREE_DATA as an indication of function availability.
 
-- icc adjustments for icc 9.0 and prior versions:
-  
-    Disable remark #279: controlling expression is constant
-  
-        Remark triggered mostly on va_arg() and FD_ZERO() macros.
+- Remove typecast
 
-- attempt to make work the gethostname function
-  check for winsock build target configurations
+- Fix comment
 
-Gisle Vanem (21 Sep 2008)
-- Added HAVE_NETDB_H, HAVE_ARPA_INET_H, HAVE_STRCASECMP
-  and HAVE_STRNCASECMP.
+- Add ares_data.c and ares_data.h
 
-Yang Tse (19 Sep 2008)
-- icc adjustments:
-  
-    Disable remark #981: operands are evaluated in unspecified order
-  
-        Function calls which are triggering this remark, today, do not depend
-        on the order of evaluation of its arguments.
-  
-    Disable remark #1469: "cc" clobber ignored
-  
-        Remark triggered on htons() and ntohs() due to glibc header files.
+- Jakub Hrozek modified ares_parse_srv_reply() and ares_parse_txt_reply() API
+  to return a linked lists of results. These were also modified to internally
+  use the ares_data memory struct and as such its result must be free'ed with
+  ares_free_data().
 
-- icc adjustments
+- Initial support for the generic ares_free_data() function that will allow
+  applications to free memory allocated and returned by some c-ares funtions.
 
-- fix netdb.h prerequisite inclusion
+- Make usage of calloc()'s arguments consistent with rest of code base
 
-- improve detection of getservbyport_r()
+- workaround icc 9.1 optimizer issue
 
-- On Linux Intel's icc uses gcc's header files, so
-  we select ANSI C89 dialect plus GNU extensions.
+- Add icc fvisibility bug test
 
-- improve detection of gethostname()
+- Fix icc 9.0 compiler warning: external definition with no prior declaration
 
-- NetWare builds include "nameser.h" from the c-ares subdir
+- Fix three var names
 
-- include <strings.h>
+- Add check for assert.h header file
 
-- Sync up with reality
+- getaddrinfo is fully thread safe on solaris versions which
+  implement the function even when h_errno is not a macro.
+  
+  The h_errno macro test now only done on systems for which there
+  is no hard coded knowledge about getaddrinfo's thread safeness.
 
-- adjust inclusion of "nameser.h"
+- Remove files generated on previous buildconf/configure run
 
-- reorder some lines in file
+- Remove enable-thread / disable-thread configure option. These were only placebo
+  options. The library is always built as thread safe as possible on every system.
 
-- code cleanup
+- Refactor how preprocessor symbol _THREAD_SAFE definition is done.
 
-- NetWare seems to have writev()
+- Assume that getaddrinfo is thread safe, unless hard coded
+  knowledge says the contrary or h_errno is not defined.
 
-- rearrange to allow internal/private use of ares_writev to any system
-  that lacks the writev function.
+- Related with the threadsafe capability of getaddrinfo:
+  
+  - Constantine Sapuntzakis reported that Darwin 6.0 a.k.a. MAC OS X 10.2
+    and newer have a threadsafe getaddrinfo.
+  
+  - Fix Dragonfly BSD triplet detection.
+  
+  - In case the hard-coded knowledge says that getaddrinfo is threadsafe,
+    an additional check is done to verify that h_errno is also defined.
+    If h_errno isn't defined, we finally assume that it isn't threadsafe.
+    Jamie Lokier provided the inspiration for this extra check.
 
-- NetWare CLIB target has stricmp() and strnicmp()
+- AIX 5.2 and newer have threadsafe getaddrinfo.
+  
+  Add some comments to better understand what the regex's pretend to achieve.
 
-- include header file only when available
+- HP-UX 11.11 and later have threadsafe getaddrinfo
 
-- rearrange to allow internal/private use of ares_strcasecmp to any system that
-  lacks the strcasecmp function.
+- Check if getaddrinfo is threadsafe when function check allows it to be used
 
-- improve detection of:
-    strcasecmp()
-    strcmpi()
-    stricmp()
-    strncasecmp()
-    strncmpi()
-    strnicmp()
+- Renamed fpGetNetworkParams and fpSystemFunction036 to avoid namespace pollution with static library
 
-- *** empty log message ***
+- Add kernel32.lib
 
-Gisle Vanem (12 Sep 2008)
-- djgpp does have strdup().
+- Mention last changes
 
-Yang Tse (12 Sep 2008)
-- change CRLF into LF line endings
+- Reinstate copyright symbol lost in previous commit
 
-- strdup() clone for systems/configurations which lack it
+- Make some strings different in resource file for debug or release builds
 
-- move inclusion of ares_private.h last
+- Ignore more subdirs
 
-- icc adjustments
+- Fix compiler warning: conditional expression is constant
 
-- icc adjustments
+- Sync linker and resource compiler options with Makefile.msvc
 
-- Select strict ANSI C89 conformance for icc
+- Follow Makefile.msvc subdirectory naming scheme, and sync compiler options
 
-- remove unnecessary typecasting of malloc()
+- Updated MSVC makefile that allows building dynamic and static
+  c-ares libraries in debug and release flavours.
+  
+  Additionally each of the three sample programs is built against
+  each of the four possible c-ares libraries, generating all this
+  a total number of 12 executables and 4 libraries.
 
-- remove unnecessary typecasting of realloc()
+- Test for USE_WINSOCK since it is more restrictive than WIN32
 
-Daniel Stenberg (29 Aug 2008)
-- we start over working towards 1.5.4
+- Make header inclusion depend on HAVE_*_H definition
 
-Version 1.5.3 (29 Aug 2008)
+- Remove unneeded preprocessor directives
 
-Daniel Stenberg (29 Aug 2008)
-- Version 1.5.3
+- Adjust c-ares include paths for memory tracking enabled (--enable-curldebug) builds
 
-- added the three people from RELEASE-NOTES and sorted the list alphabetically
+- source files used by sample programs
 
-Yang Tse (27 Aug 2008)
-- Don't abort configuration if recvfrom() is not available.
+- Renamed c-ares setup.h to ares_setup.h
 
-- Functionality only possible if recvfrom() is available.
+- Adjust include paths to take in account that currently:
+  
+  c-ares with --enable-curldebug uses memdebug.h from libcurl's lib subdirectory.
+  
+  memdebug.h needs access to libcurl's setup.h from libcurl's lib subdirectory
+  and also needs access to libcurl's generated curl_config.h
 
-- George Neill's fix acountry sample application compilation failure.
+- Undo old temporary change once used for testing purposes
 
-- Brad House's validation that DNS response address matches the request address
+- Mention many changes
 
-- fix the output name
+- Mention --enable-symbol-hiding configure option
 
-- Get rid of ENABLE_64BIT symbol definition and usage.
+- Symbol hiding configure options renamed to the hopefully less ambiguous
+  --enable-symbol-hiding and --disable-symbol-hiding as well as related
+  macro names and some internal variables used for them.
   
-  Improve HAVE_LONGLONG symbol description.
-
-- Export 'ares_process_fd' too.
-
-Gisle Vanem (16 Aug 2008)
-- Ops, remove 'use_vc'.
+  Related configuration file preprocessor symbols named to
+  CARES_SYMBOL_HIDING and CARES_SYMBOL_SCOPE_EXTERN.
 
-- Support Watt-32 under Win32.
+- Header inclusion depending on HAVE_* symbol.
+  Fix two typos.
 
-Yang Tse (10 Aug 2008)
-- Fix: Remove now this SIZEOF_CURL_OFF_T symbol definition.
+- Comparison of the Initial revision of this file with ares_parse_a_reply.c
+  shows that this one is actually a modified copy of ares_parse_a_reply.c.
   
-  This should have been done with the initial 64-bit curl_off_t patch.
+  In order to comply with ares_parse_a_reply.c's M.I.T. license, the old
+  1998 M.I.T. copyright notice is now also preserved in this file the same
+  as it is done in other ares_parse_*.c files.
 
-- Improve CURL_CHECK_DEF
+- Add CVS Id tag.
+  Fix identation of some license lines.
 
-- Fix IBM C and DEC/Compaq C compiler detection
+- Add CVS Id tag.
 
-- Initial support of curlbuild.h and curlrules.h which allows
-  to have a curl_off_t data type no longer gated to off_t.
+- Fix comment
 
-- The minimum autoconf version required for this file is 2.50
+- In no particular order, changed/fixed all of the following in
+  ares_parse_txt_reply() current version:
   
-  Avoid dot notation in aclocal serial file number, use a single number now.
-
-Daniel Stenberg (4 Aug 2008)
-- - Fix by Tofu Linden:
+  - Fixed a couple of potential double free's.
   
-    The symptom:
-    * Users (usually, but not always) on 2-Wire routers and the Comcast service
-    and a wired connection to their router would find that the second and
-    subsequent DNS lookups from fresh processes using c-ares to resolve the same
-    address would cause the process to never see a reply (it keeps polling for
-    around 1m15s before giving up).
+  - Fixed memory leaks upon out of memory condition.
   
-    The repro:
-    * On such a machine (and yeah, it took us a lot of QA to find the systems
-    that reproduce such a specific problem!), do 'ahost www.secondlife.com',
-    then do it again.  The first process's lookup will work, subsequent lookups
-    will time-out and fail.
+  - Fixed pointer arithmetic.
   
-    The cause:
-    * init_id_key() was calling randomize_key() *before* it initialized
-    key->state, meaning that the randomness generated by randomize_key() is
-    immediately overwritten with deterministic values. (/dev/urandom was also
-    being read incorrectly in the c-ares version we were using, but this was
-    fixed in a later version.)
-    * This makes the stream of generated query-IDs from any new c-ares process
-    be an identical and predictable sequence of IDs.
-    * This makes the 2-Wire's default built-in DNS server detect these queries
-    as probable-duplicates and (erroneously) not respond at all.
-
-Yang Tse (4 Aug 2008)
-- Autoconf 2.62 has changed the behaviour of the AC_AIX macro which we use.
-  Prior versions of autoconf defined _ALL_SOURCE if _AIX was defined. But,
-  autoconf 2.62 version of AC_AIX defines _ALL_SOURCE along with other four
-  preprocessor symbols no matter if the system is AIX or not. To keep the
-  traditional behaviour, as well as an uniform one, across autoconf versions
-  AC_AIX is replaced with our own internal macro.
-
-- Adjust DEC/Compaq C compiler settings.
-
-- Another AC_TRY_LINK conversion to AC_LINK_IFELSE.
-  Proper definition of HAVE_function if function is found deeper.
-
-- Sync up with reality
-
-- Rename reentrant.m4 to avoid filename clash.
-
-- Add file version serial number that might be used by 'aclocal' and others.
+  - Setting ntxtreply to zero upon entry for all failure cases.
   
-  Keep the '#' character as the first one on the line.
-
-- Update copyright year.
-
-- Sync comment with reality.
-
-- Reinstate the 'aclocal -I m4' in buildconf and 'ACLOCAL_AMFLAGS = -I m4' way of
-  including our local m4/reentrant.m4 file. This even takes care of including the
-  file in the distribution tarball.
-
-- Add quoting for the AC_DEFINE arguments.
-
-- Also remove the whitespace.
-
-- Also remove the extra quoting.
-
-- Replace some '@%:@' quadigraphs by its actual representation '#'.
+  - Changed data type to size_t for variables substr_len, str_len and
+    the length member of ares_txt_reply struct.
   
-  This quadigraph used before a C preprocessor 'define' directive could
-  be fooling M4, when processing this file, and make it think that the
-  line contains a pure M4 'define' macro.
-
-- Tests done using 'aclocal -I m4' in buildconf and 'ACLOCAL_AMFLAGS = -I m4
-  in top Makefile.am triggered a problem that prevented aclocal from running
-  successfully on SunOS 5.10 with GNU m4 1.4.5 and GNU Autoconf 2.61
+  - Avoided a couple of memcpy() calls.
   
-  A tarball which reproduces mentioned problem is the one dated July-28-2008
-  http://cool.haxx.se/curl-daily/curl-7.19.0-20080728.tar.gz
+  - Changed i data type to unsigned int to prevent compiler warnings.
   
-  We actually don't need all the bells and whistles that the above mechanism
-  provides. We only need to include our m4/reentrant.m4 file in acinclude.m4
-  so here we go with this simpler mechanism.
-
-- for debugging purposes show ACLOCAL_FLAGS
+  - Adjusted a comment.
+  
+  - Use ARES_SUCCESS literal for successfull completion.
+  
+  - Added CVS Id tag.
 
-- These lines were unintentionally removed in previous commit
+- Add c-ares DLL resource file to distribution archive
 
-- Partially undo change that prevented SED, GREP, EGREP and AR from being changed by libtool or autoconf.
+- ignore files
 
-- Assert that SED and GREP are set
+- Empty subdir
 
-- Require autoconf 2.57 or newer
+- Updated MSVC 6.0 workspace and project files that allows building
+  dynamic and static c-ares libraries in debug and release flavours.
+  
+  Additionally each of the three sample programs is built against
+  each of the four possible c-ares libraries, generating all this
+  a total number of 12 executables and 4 libraries.
 
-- When calling aclocal, user defined ACLOCAL_FLAGS will now precede ours.
+Daniel Stenberg (29 Oct 2009)
+- no need to check for NULL pointers before dereferencing, as the pointers
+  MUST be valid and they are dereferenced further down in the function
+  unconditionally!
 
-- move ACLOCAL_AMFLAGS after AUTOMAKE_OPTIONS
+- shorten the descriptions somewhat
 
-- setup.h handles definition of _REENTRANT based on NEED_REENTRANT
-  definition which might be defined in config.h or config-*.h files
+- update to the new struct name
 
-- Remove explicit inclusion of our m4 files first. It was interesting as a test,
-  but it breaks aclocal execution on some systems, with the following error:
-  
-  Can't locate object method "rel2abs" via package "File::Spec" at /usr/local/bin/aclocal line 256.
+- Jakub Hrozek added ares_parse_txt_reply() for TXT parsing
 
-- Another step towards detecting if _REENTRANT is already defined or actually
-  needed, and being able to define it if appropriate for further configure tests
-  as well as for the generated config file.
+- use 'ares_srv_reply' for proper name-spacing
 
-- Explicitly include our m4 files first. This might minimize the impact
-  that other package's underquoted m4 function definitions have on ours.
+Yang Tse (29 Oct 2009)
+- Add reference for ares_parse_srv_reply.pdf
 
-- Add a 3 argument check for getprotobyname_r
+- Add reference for ares_parse_srv_reply docs
 
-- move reentrant.m4 to the m4 subdirectory to avoid infinite loop inclusion problem
+- External API function linkage decoration adjustment
 
-- add checks for strtok_r and getprotobyname_r
+- External API function linkage decoration adjustment
 
-- Another step towards detecting if _REENTRANT is already defined or actually
-  needed, and being able to define it if appropriate for further configure tests
-  as well as for the generated config file.
+- Initial step towards the ability to reduce c-ares exported symbols
+  based on the 'visibility' attribute for GNUC and __global for Sun
+  compilers, taking also in account __declspec function decoration
+  for Win32 and Symbian DLL's.
   
-  Introduced reentrant.m4 intended for our reentrant related autotools/m4 macros.
+  Introducing configure options --enable-hidden-symbols and
+  --disable-hidden-symbols following libcurl's naming.
 
-- reorder argument number detection for getservbyport_r to
-  actually verify if the test is properly working
+- Fix comment
 
-- Make sure that configure process tests are done with the same _REENTRANT
-  setting as the one actually used when finally building the library.
+- Fix spelling
 
-- Change recvfrom's sixth argument data type to the 'historically standard' 'int'
-  data type for systems where this sixth argument is prototyped as a void pointer.
-  
-  Start of thread: http://curl.haxx.se/mail/lib-2008-07/0153.html
+- Fix Pelles C Win32 target compilation issues
 
-- use prototypes to improve getservbyport_r detection
+- John Engelhart noticed an unreleased problem relative to a duplicate
+  ARES_ECANCELLED error code value and missing error code description.
 
-- Adjust recvfrom's sixth arg data type definition for NetWare (LIBC)
+- Fix compiler warning: local variable may be used without having been initialized
 
-- Use the sreadfrom() wrapper to replace recvfrom() in our code.
+- Use *_CHECK_PATH_SEPARATOR_REQUIRED to ensure that *_CHECK_PATH_SEPARATOR
+  is only expanded and included once in the configure script.
 
-- when recvfrom prototype uses a void pointer for arguments 2, 5 or 6 this will
-  now cause the definition of RECVFROM_TYPE_ARG2_IS_VOID, RECVFROM_TYPE_ARG5_IS_VOID
-  or RECVFROM_TYPE_ARG6_IS_VOID, as appropriate.
+- Our _AS_PATH_SEPARATOR_PREPARE override is now m4_defun'd instead of m4_define'd
+  due to autoconf 2.64 m4_require'ing it in _AS_SHELL_SANITIZE indirectly through
+  _AS_PATH_WALK.
 
-- Adjust DEC/Compaq C compiler settings
+- Fix compiler warning: argument is incompatible with corresponding format string conversion
 
-- Added "pointer to void" as another data type to check for the sixth argument of
-  function recvfrom as a result of the info additionally logged when running on a
-  Solaris system.
-  
-  The compiler error showed that the prototype being used on Solaris was the one
-  declared in line 427 of "/usr/include/sys/socket.h" as:
-  
-  function(int,
-           pointer to void,
-           unsigned int,
-           int,
-           pointer to struct sockaddr,
-           pointer to void) returning int
+- Fix potential out-of-bounds read
+
+- Fix compiler warning: loop without body
 
-- Adjust DEC/Compaq C compiler settings
+- Fix compiler warning
 
-- RECVFROM_TYPE_ARG2, RECVFROM_TYPE_ARG5 and RECVFROM_TYPE_ARG6 are now defined
-  to the data type pointed by its respective argument and not the pointer type.
+- Fix compiler warning
 
-- Configure process now checks availability of recvfrom() socket function and
-  finds out its return type and the types of its arguments. Added definitions
-  for non-configure systems config files, and introduced macro sreadfrom which
-  will be used on udp sockets as a recvfrom() wrapper.
+- Fix compiler warning
 
-- Initial DEC/Compaq C compiler detection and flags
+- Fix compiler warning: addition result could be truncated before cast to bigger sized type
 
-- Improved configure detection of number of arguments for getservbyport_r
+- Overhauled ares__get_hostent()
+  
+  - Fixing out of bounds memory overwrite triggered with malformed /etc/hosts file.
+  - Improving parsing of /etc/hosts file.
+  - Validating requested address family.
+  - Ensuring that failures always return a NULL pointer.
+  - Adjusting header inclusions.
 
-- Allow --enable-largefile and --disable-largefile configurations.
-  Configure process no longer needs nor checks size of curl_off_t.
-  Library will now be built with _REENTRANT symbol defined.
+- Fix ssize_t redefinition errors on WIN64 reported by Alexey Simak
 
-- fix compiler warning
+- more files to ignore
 
-- since Jun 30 2008 MAXHOSTNAMELEN define is no longer used
+- Check if _REENTRANT definition is required to
+  make errno available as a preprocessor macro.
 
-- fix c-ares version reported in generated libcares.pc file when building
-  from CVS tree.
+- Attempt to silence bogus compiler warning: "Potential null pointer dereference"
 
-- egrep and ar are also mandatory
+- ignore more files
 
-Daniel Stenberg (3 Jul 2008)
-- just to clarify that c-ares actually have some ipv6 support
+Gisle Vanem (7 Sep 2009)
+- Suppress warnings about unused prototypes in Watt32 and Win32 programs.
 
-- ares_gethostbyname() fallback from AAA to A records with CNAME present
+- Update email address.
 
-- - Phil Blundell: If you ask ares_gethostbyname() to do an AF_INET6 lookup and
-    the target host has only A records, it automatically falls back to an
-    AF_INET lookup and gives you the A results.  However, if the target host has
-    a CNAME record, this behaviour is defeated since the original query does
-    return some data even though ares_parse_aaa_reply() doesn't consider it
-    relevant. Here's a small patch to make it behave the same with and without
-    the CNAME.
+- Update my email address. Add ares_config.h as dependency for 'make depend'.
 
-Yang Tse (2 Jul 2008)
-- The configure process will now halt when sed or grep are unavailable
+Yang Tse (6 Sep 2009)
+- T_SRV portability check
 
-- fallback to gettimeofday when monotonic clock is unavailable at run-time
+Gunter Knauf (5 Sep 2009)
+- changed includes to match style how we do with all other *.c files.
 
-- IBM C/C++ compiler predefined macro check
+- changed u_int16_t to unsigned short because it is the only place within ares and curl where such a type would be used;
+  also it broke many autobuilds. We should probably introduce an ares_port_t if we want to use a type here.
 
-- set earlier in configure process IBM compilers optimization flags
+Gisle Vanem (5 Sep 2009)
+- Replace 'uint16_t' with 'u_int16_t' since the latter is used in ares.h.
 
-- make check message wording more precise
+- Added 'ares_parse_srv_reply.obj'. Added definition of 'u_int16_t'. This is I don't like; we should not depend on such non-universal types in a public header. But this is just a quick fix.
 
-Daniel Stenberg (30 Jun 2008)
-- - As was pointed out to me by Andreas Schuldei, the MAXHOSTNAMELEN define is
-    not posix or anything and thus c-ares failed to build on hurd (and possibly
-    elsewhere). The define was also somewhat artificially used in the windows
-    port. Now, I instead rewrote the use of gethostbyname to enlarge the host
-    name buffer in case of need and totally avoid the use of the MAXHOSTNAMELEN
-    define. I thus also removed the defien from the namser.h file where it was
-    once added for the windows build.
-  
-    I also fixed init_by_defaults() function to not leak memory in case if
-    error.
+Daniel Stenberg (4 Sep 2009)
+- - Jakub Hrozek added ares_parse_srv_reply() for SRV parsing
 
-Yang Tse (29 Jun 2008)
-- fix C style comment
+Steinar H. Gunderson (27 Aug 2009)
+- Support lookup of IPv4 literals in ares_gethostbyname(), even when the address family is set to AF_INET6.
 
-- John Lightsey filed bug report #1999181: "CLOCK_MONOTONIC always fails on
-  some systems" (http://curl.haxx.se/bug/view.cgi?id=1999181). The problem was
-  that the configure script did not use the _POSIX_MONOTONIC_CLOCK feature test
-  macro when checking monotonic clock availability. This is now fixed and the
-  monotonic clock will not be used unless the feature test macro is defined
-  with a value greater than zero indicating always supported.
+Gisle Vanem (3 Aug 2009)
+- Remove call to LoadLibrary(). (leftover from debugging).
 
-- Modified configuration script to actually verify if the compiler is good
-  enough at detecting compilation errors or at least it has been properly
-  configured to do so. Configuration heavily depends on this capability, so
-  if this compiler sanity check fails the configuration process will now fail.
+- Fix bad sentence.
 
-- No longer break out of a shell "for" statement from inside
-  AC_FOO_IFELSE macros, otherwise temp files are not removed.
-  
-  Identation adjustment.
+Daniel Stenberg (3 Aug 2009)
+- - Timo Teras changed the reason code used in the resolve callback done when
+    ares_cancel() is used, to be ARES_ECANCELLED instead of ARES_ETIMEOUT to
+    better allow the callback to know what's happening.
 
-Gunter Knauf (11 Jun 2008)
-- enable additional CFLAGS from commandline.
+- - Joshua Kwan fixed the init routine to fill in the defaults for stuff that
+    fails to get inited by other means. This fixes a case of when the c-ares
+    init fails when internet access is fone.
 
-Yang Tse (9 Jun 2008)
-- fix pkg-config reporting of private libraries needed for static linking
+Gunter Knauf (16 Jul 2009)
+- test if adding ../lib to includes can fix the current break ...
 
-- MSVC does build Windows native targets
+- renamed generated config.h to ares_config.h in order to avoid clashes when libcurl is used with other projects which also have a config.h.
 
-- Brad House fixed a missing header file inclusion in adig sample program
+Yang Tse (21 Jun 2009)
+- Refactor how libraries are checked for connect() function, follow-up.
 
-Daniel Stenberg (29 May 2008)
-- start working on 1.5.3
+- Refactor how libraries are checked for connect() function,
+  and check for connect() as it is done for other functions.
 
-Version 1.5.2 (29 May 2008)
+Gisle Vanem (20 Jun 2009)
+- Remove unneeded defines.
 
-Daniel Stenberg (29 May 2008)
-- 1.5.2
+- Use select_s() and not select().
 
-Yang Tse (26 May 2008)
-- fix compiler warning: unreferenced formal parameter
+Yang Tse (19 Jun 2009)
+- sclose() function-like macro definition used to close a socket,
+  now solely based on HAVE_CLOSESOCKET and HAVE_CLOSESOCKET_CAMEL
+  config file preprocessor definitions.
 
-Daniel Stenberg (23 May 2008)
-- list all local sources the (demo) tools need, add a few missing scripts to
-  the dist tarball and remove a two duplicate file names from EXTRA_DIST
-  (most of it pointed out by Yang Tse)
+- add CloseSocket camel case function check
 
-- this is not used (anymore)
+- check for socket() and closesocket() as it is done for other functions
 
-- make sure the configure.ac file with the correct version number is shipped
-  in the tarball
+- Remove HAVE_CONFIG_H definition from here,
+  CFLAGS from common.dj already defines it.
 
-Yang Tse (22 May 2008)
-- MSVC6+ clean-up targets must also remove acountry.exe
+- initial step towards decoupling c-ares from libcurl for DOS
 
-- sync with reality
+- don't ignore these subdirs, they must be removed first
 
-- fix: [action-if-found] part of AC_CHECK_TYPE macro cannot be quoted when empty
+- Remove DEBUGBUILD symbol definition, is not required for programs using the library.
 
-- fix: remove need and definition of HAVE_SOCKLEN_T symbol
+- DEBUGBUILD symbol definition for debug builds
 
-- fix: socklen_t definition comment
+- ignore some subdirs
 
-- update several macros using AC_TRY_LINK with AC_LINK_IFELSE
+- fix comment
 
-- fix underquoting of AC_LANG_PROGRAM arguments
+- Try to make more clear that --enable-curldebug has nothing to do with --enable-debug for this library.
 
-- if'def out private function ares__tvdiff(), it is not in use yet.
+- Revert last change, it is inappropriate.
 
-- update several macros using AC_TRY_LINK with AC_LINK_IFELSE
+Gisle Vanem (12 Jun 2009)
+- Replace CURLDEBUG with DEBUGBUILD.
 
-- fix socklen_t equivalent detection when cross compiling Windows target
+Yang Tse (11 Jun 2009)
+- when running automake copy missing files instead of symlinking them
 
-- if WINSOCK2 API is used link with 'ws2_32', else
+- Adjusted to take in account that...
+  
+  With the curl memory tracking feature decoupled from the debug build feature,
+  CURLDEBUG and DEBUGBUILD preprocessor symbol definitions are used as follows:
   
-  if WINSOCK API is used under WinCE link with 'winsock', else
+  CURLDEBUG used for curl debug memory tracking specific code (--enable-curldebug)
   
-  if WINSOCK API is used link with 'wsock32'.
+  DEBUGBUILD used for debug enabled specific code (--enable-debug)
 
-- on winsock systems linking is done using library 'ws2_32' when
-  winsock2.h is available, and library 'winsock' is used when only
-  winsock.h is available.
+- c-ares' --enable-debug --enable-curldebug decoupling follow-up
 
-- minor change for wince-cegcc and wince-mingw32ce support
+- mention last changes
 
-- millisecond resolution support followup
+- Remove buildconf.bat from release and daily snapshot archives.
+  
+  buildconf.bat is only for CVS tree builds.
 
-Gisle Vanem (15 May 2008)
-- Replaced "-DHAVE_FIONBIO" with "-DHAVE_IOCTLSOCKET".
-  Added "-DHAVE_GETTIMEOFDAY". Trimmed lines.
+- Ensure that buildconf.bat does nothing unless it is used with a CVS checkout.
 
-Yang Tse (15 May 2008)
-- sync with reality
+- CVS-INFO file only present in CVS tree, never in release nor daily snapshot
+  archives. Used as a sentinel file in buildconf.bat to differentiate CVS builds.
 
-- remove compilation time generated files
+Gisle Vanem (8 Jun 2009)
+- Update comment about "ML". Removed "-D_USE_32BIT_TIME_T" (not a requirement).
 
-- use same time source for timeout initialization and processing
+Yang Tse (8 Jun 2009)
+- just comment it out
 
-- Improve toolchain detection for WinCE cross compilation:
-  
-  When cross compiling WinCE with the arm-wince-cegcc-gcc C compiler
-  symbol __CEGCC__ is defined and the unix-like compatibility layer
-  is used. For our purposes this is not a native Windows build.
+- For debugging purposes...
   
-  When cross compiling WinCE with the arm-wince-mingw32ce-gcc C compiler
-  symbol __MINGW32CE__ is defined and the unix-like compatibility layer
-  is not used. For our purposes this _is_ a native Windows build.
+  Disable the '-export-symbols-regex' to discard this as the origin
+  of link failures related with shared libraries and non-GNU linkers.
 
-- skip checks for Windows specific header files
-  when build target is not a native Windows one
+- c-ares Makefile.am back to using $(top_builddir) for *_LDADD
 
-- WinCE cross compilation adjustments:
-  
-  HAVE_WINSOCK2_H shall not be defined.
-  HAVE_WS2TCPIP_H shall not be defined.
+- c-ares' -no-undefined and --enable-curldebug adjustments
+
+- Use relative path to built c-ares tree libtool library
+
+- John E. Malmberg noticed that the configure script was failing to detect the
+  timeval struct on VMS when building with _XOPEN_SOURCE_EXTENDED undefined due
+  to definition taking place in socket.h instead of time.h
 
-Daniel Stenberg (13 May 2008)
-- - Introducing millisecond resolution support for the timeout option. See
-    ares_init_options()'s ARES_OPT_TIMEOUTMS.
+- Fix compiler warning: out of bound access