]> sourceware.org Git - glibc.git/commitdiff
* resolv/Versions [libresolv] (GLIBC_PRIVATE): Add
authorUlrich Drepper <drepper@redhat.com>
Tue, 30 Oct 2007 00:58:03 +0000 (00:58 +0000)
committerUlrich Drepper <drepper@redhat.com>
Tue, 30 Oct 2007 00:58:03 +0000 (00:58 +0000)
_nss_dns_getnetbyaddr2_r.
* resolv/nss_dns/dns-host.c: Define _nss_dns_getnetbyaddr2_r.  Pass
extra parameter to getanswer_r.
(_nss_dns_getnetbyaddr_r): Now a wrapper around
_nss_dns_getnetbyaddr2_r.

ChangeLog
resolv/Versions
resolv/nss_dns/dns-host.c

index 53f636ec10e8bcff334da16a8758dc458c10f3c8..e8afd16cdbf5e20199a0b2b5c1a41af5c2bbbe22 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,12 @@
 2007-10-29  Ulrich Drepper  <drepper@redhat.com>
 
+       * resolv/Versions [libresolv] (GLIBC_PRIVATE): Add
+       _nss_dns_getnetbyaddr2_r.
+       * resolv/nss_dns/dns-host.c: Define _nss_dns_getnetbyaddr2_r.  Pass
+       extra parameter to getanswer_r.
+       (_nss_dns_getnetbyaddr_r): Now a wrapper around
+       _nss_dns_getnetbyaddr2_r.
+
        * nscd/Makefile (nscd-modules): Replace gethstbynm2_r with
        gethstbynm3_r.
        * nscd/gethstbynm2_r.c: Remove.
index 5a350cae36342815f119488782f963bfcf11411c..fc2111a1cb0ef045355572a87da2e6ed638821a3 100644 (file)
@@ -88,6 +88,7 @@ libnss_dns {
     _nss_dns_gethostbyname3_r;
     _nss_dns_gethostbyname_r; _nss_dns_getnetbyaddr_r;
     _nss_dns_getnetbyname_r; _nss_dns_getcanonname_r;
+    _nss_dns_gethostbyaddr2_r;
   }
 }
 
index 0e25564670d9470bf88df0a2c411efb47a371862..def44e9dbf5a1c03414511d0a7ac24079b484906 100644 (file)
@@ -255,10 +255,18 @@ _nss_dns_gethostbyname_r (const char *name, struct hostent *result,
 }
 
 
+extern enum nss_status _nss_dns_gethostbyaddr2_r (const void *addr,
+                                                 socklen_t len, int af,
+                                                 struct hostent *result,
+                                                 char *buffer, size_t buflen,
+                                                 int *errnop, int *h_errnop,
+                                                 int32_t *ttlp);
+hidden_proto (_nss_dns_gethostbyaddr2_r)
+
 enum nss_status
-_nss_dns_gethostbyaddr_r (const void *addr, socklen_t len, int af,
-                         struct hostent *result, char *buffer, size_t buflen,
-                         int *errnop, int *h_errnop)
+_nss_dns_gethostbyaddr2_r (const void *addr, socklen_t len, int af,
+                          struct hostent *result, char *buffer, size_t buflen,
+                          int *errnop, int *h_errnop, int32_t *ttlp)
 {
   static const u_char mapped[] = { 0,0, 0,0, 0,0, 0,0, 0,0, 0xff,0xff };
   static const u_char tunnelled[] = { 0,0, 0,0, 0,0, 0,0, 0,0, 0,0 };
@@ -374,7 +382,7 @@ _nss_dns_gethostbyaddr_r (const void *addr, socklen_t len, int af,
 
  got_it_already:
   status = getanswer_r (host_buffer.buf, n, qbuf, T_PTR, result, buffer, buflen,
-                       errnop, h_errnop, 0 /* XXX */, NULL, NULL);
+                       errnop, h_errnop, 0 /* XXX */, ttlp, NULL);
   if (host_buffer.buf != orig_host_buffer)
     free (host_buffer.buf);
   if (status != NSS_STATUS_SUCCESS)
@@ -408,6 +416,17 @@ _nss_dns_gethostbyaddr_r (const void *addr, socklen_t len, int af,
   *h_errnop = NETDB_SUCCESS;
   return NSS_STATUS_SUCCESS;
 }
+hidden_def (_nss_dns_gethostbyaddr2_r)
+
+
+enum nss_status
+_nss_dns_gethostbyaddr_r (const void *addr, socklen_t len, int af,
+                         struct hostent *result, char *buffer, size_t buflen,
+                         int *errnop, int *h_errnop)
+{
+  return _nss_dns_gethostbyaddr2_r (addr, len, af, result, buffer, buflen,
+                                   errnop, h_errnop, NULL);
+}
 
 #ifdef RESOLVSORT
 static void addrsort (char **ap, int num);
This page took 0.051351 seconds and 5 git commands to generate.