about summary refs log tree commit diff
path: root/nscd
diff options
context:
space:
mode:
authorUlrich Drepper <drepper@redhat.com>2001-09-12 03:53:07 +0000
committerUlrich Drepper <drepper@redhat.com>2001-09-12 03:53:07 +0000
commit57642a78929e35d58c25f416f523670effdc0f70 (patch)
treeaf543e6c01f354fe5894b66dbf382962a9d1e791 /nscd
parent455e8060b03bc12a2b3a25c9be92b5e420d806fd (diff)
downloadglibc-57642a78929e35d58c25f416f523670effdc0f70.tar.gz
glibc-57642a78929e35d58c25f416f523670effdc0f70.tar.xz
glibc-57642a78929e35d58c25f416f523670effdc0f70.zip
Update.
2001-09-11  Ulrich Drepper  <drepper@redhat.com>

	* nscd/nscd_gethst_r.c: Don't expect IPv6 addresses for IPv4 lookup.
	Patch by Stephan Kulow.
Diffstat (limited to 'nscd')
-rw-r--r--nscd/nscd_gethst_r.c10
1 files changed, 3 insertions, 7 deletions
diff --git a/nscd/nscd_gethst_r.c b/nscd/nscd_gethst_r.c
index ea2d674056..d371922430 100644
--- a/nscd/nscd_gethst_r.c
+++ b/nscd/nscd_gethst_r.c
@@ -1,4 +1,4 @@
-/* Copyright (C) 1998, 1999, 2000 Free Software Foundation, Inc.
+/* Copyright (C) 1998, 1999, 2000, 2001 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
    Contributed by Ulrich Drepper <drepper@cygnus.com>, 1998.
 
@@ -219,10 +219,6 @@ nscd_gethst_r (const char *key, size_t keylen, request_type type,
 	  vec[2].iov_base = cp;
 	  vec[2].iov_len = hst_resp.h_addr_list_cnt * INADDRSZ;
 
-	  ignore = alloca (hst_resp.h_addr_list_cnt * IN6ADDRSZ);
-	  vec[3].iov_base = ignore;
-	  vec[3].iov_len = hst_resp.h_addr_list_cnt * IN6ADDRSZ;
-
 	  for (cnt = 0; cnt < hst_resp.h_addr_list_cnt; ++cnt)
 	    {
 	      resultbuf->h_addr_list[cnt] = cp;
@@ -232,9 +228,9 @@ nscd_gethst_r (const char *key, size_t keylen, request_type type,
 	  resultbuf->h_addrtype = AF_INET;
 	  resultbuf->h_length = INADDRSZ;
 
-	  total_len += hst_resp.h_addr_list_cnt * (INADDRSZ + IN6ADDRSZ);
+	  total_len += hst_resp.h_addr_list_cnt * INADDRSZ;
 
-	  n = 4;
+	  n = 3;
 	}
       else
 	{