summaryrefslogtreecommitdiff
path: root/ares_getnameinfo.c
diff options
context:
space:
mode:
authorYang Tse <yangsita@gmail.com>2010-11-12 19:00:29 +0100
committerYang Tse <yangsita@gmail.com>2010-11-12 19:00:29 +0100
commit494274e653936335c255a47599970de3df21e7c4 (patch)
tree7e8ada73e8c741fbbae22f94535cf2d18c7c19ad /ares_getnameinfo.c
parent747981be8eadc4d8be5bc673c0b64efa556adf4e (diff)
downloadc-ares-494274e653936335c255a47599970de3df21e7c4.tar.gz
c-ares-494274e653936335c255a47599970de3df21e7c4.tar.bz2
c-ares-494274e653936335c255a47599970de3df21e7c4.zip
Fix GCC 4 compiler warning 'dereferencing type-punned pointer might break strict-aliasing rules'.
Diffstat (limited to 'ares_getnameinfo.c')
-rw-r--r--ares_getnameinfo.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/ares_getnameinfo.c b/ares_getnameinfo.c
index 8ae2f02..49250ed 100644
--- a/ares_getnameinfo.c
+++ b/ares_getnameinfo.c
@@ -366,8 +366,8 @@ static void append_scopeid(struct sockaddr_in6 *addr6, unsigned int flags,
tmpbuf[0] = '%';
#ifdef HAVE_IF_INDEXTONAME
- is_ll = IN6_IS_ADDR_LINKLOCAL(&addr6->sin6_addr);
- is_mcll = IN6_IS_ADDR_MC_LINKLOCAL(&addr6->sin6_addr);
+ is_ll = IN6_IS_ADDR_LINKLOCAL((void *)&addr6->sin6_addr);
+ is_mcll = IN6_IS_ADDR_MC_LINKLOCAL((void *)&addr6->sin6_addr);
if ((flags & ARES_NI_NUMERICSCOPE) ||
(!is_ll && !is_mcll))
{