]> git.ipfire.org Git - thirdparty/glibc.git/commitdiff
(gethostbyaddr): Try ip6.int if ip6.arpa fails.
authorUlrich Drepper <drepper@redhat.com>
Fri, 2 Aug 2002 20:20:03 +0000 (20:20 +0000)
committerUlrich Drepper <drepper@redhat.com>
Fri, 2 Aug 2002 20:20:03 +0000 (20:20 +0000)
resolv/gethnamaddr.c

index 117e4a321e76906018a82e49a878f46d1b8caa9c..14758df23138eae73c6b187b567f50349b7fff95 100644 (file)
@@ -696,6 +696,10 @@ gethostbyaddr(addr, len, af)
                abort();
        }
        n = res_nquery(&_res, qbuf, C_IN, T_PTR, (u_char *)buf.buf, sizeof buf.buf);
+       if (n < 0 && af == AF_INET6) {
+               strcpy(qp, "ip6.int");
+               n = res_nquery(&_res, qbuf, C_IN, T_PTR, (u_char *)buf.buf, sizeof buf.buf);
+       }
        if (n < 0) {
                dprintf("res_nquery failed (%d)\n", n);
                if (errno == ECONNREFUSED)