Require c-ares >= 1.5

Version 1.5 was released on 21-nov-2007. RHEL, Suse, etc supported versions
are all above c-ares v1.5.

We don't bother testing for it at build time for now, because it's non-trivial
(times two build systems).

Change-Id: I9253256d8d905da0c75d80b2b0fa4527df2b1420
Reviewed-on: https://code.wireshark.org/review/22741
Petri-Dish: João Valverde <j@v6e.pt>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
This commit is contained in:
João Valverde 2017-07-20 19:03:45 +01:00 committed by Anders Broman
parent 9e419f62bd
commit d238160a22
1 changed files with 2 additions and 31 deletions

View File

@ -348,13 +348,6 @@ typedef struct _async_hostent {
void *addrp;
} async_hostent_t;
#if ( ( ARES_VERSION_MAJOR < 1 ) \
|| ( 1 == ARES_VERSION_MAJOR && ARES_VERSION_MINOR < 5 ) )
static void c_ares_ghba_cb(void *arg, int status, struct hostent *hostent);
#else
static void c_ares_ghba_cb(void *arg, int status, int timeouts _U_, struct hostent *hostent);
#endif
ares_channel ghba_chan; /* ares_gethostbyaddr -- Usually non-interactive, no timeout */
ares_channel ghbn_chan; /* ares_gethostbyname -- Usually interactive, timeout */
@ -845,18 +838,7 @@ fill_dummy_ip6(hashipv6_t* volatile tp)
#ifdef HAVE_C_ARES
static void
c_ares_ghba_cb(
void *arg,
int status,
#if ( ( ARES_VERSION_MAJOR < 1 ) \
|| ( 1 == ARES_VERSION_MAJOR && ARES_VERSION_MINOR < 5 ) )
struct hostent *he
#else
int timeouts _U_,
struct hostent *he
#endif
) {
c_ares_ghba_cb(void *arg, int status, int timeouts _U_, struct hostent *he) {
async_dns_queue_msg_t *caqm = (async_dns_queue_msg_t *)arg;
char **p;
@ -3103,18 +3085,7 @@ eui64_to_display(wmem_allocator_t *allocator, const guint64 addr_eui64)
#ifdef HAVE_C_ARES
#define GHI_TIMEOUT (250 * 1000)
static void
c_ares_ghi_cb(
void *arg,
int status,
#if ( ( ARES_VERSION_MAJOR < 1 ) \
|| ( 1 == ARES_VERSION_MAJOR && ARES_VERSION_MINOR < 5 ) )
struct hostent *hp
#else
int timeouts _U_,
struct hostent *hp
#endif
) {
c_ares_ghi_cb(void *arg, int status, int timeouts _U_, struct hostent *hp) {
/*
* XXX - If we wanted to be really fancy we could cache results here and
* look them up in get_host_ipaddr* below.