]> git.ipfire.org Git - thirdparty/coreutils.git/commitdiff
(canon_host) [HAVE_GETADDRINFO]: Use `= { 0, };' to initialize local `hint'.
authorPaul Eggert <eggert@cs.ucla.edu>
Fri, 24 Jun 2005 17:33:58 +0000 (17:33 +0000)
committerPaul Eggert <eggert@cs.ucla.edu>
Fri, 24 Jun 2005 17:33:58 +0000 (17:33 +0000)
lib/ChangeLog
lib/canon-host.c

index f71d0fcf02ef4383e199b389bbb7d5808cf7d5fb..eb9418bc12671ea55b4e392f611b5af91c1de1eb 100644 (file)
@@ -1,3 +1,9 @@
+2005-06-24  Paul Eggert  <eggert@cs.ucla.edu>
+
+       * canon-host.c (canon_host) [HAVE_GETADDRINFO]: Use `= { 0, };' to
+       initialize local `hint'.  This undoes the previous change, and
+       syncs with gnulib.
+
 2005-06-23  Jim Meyering  <jim@meyering.net>
 
        * Makefile.am (libcoreutils_a_SOURCES): Remove xreadlink.c
index a36428db66fe15c177c35cdba75ea60b8167fb25..0d469ba1a48164bb700f28d23a1c8d32eb3bfa94 100644 (file)
@@ -54,9 +54,8 @@ canon_host (char const *host)
 
 #if HAVE_GETADDRINFO
   {
-    struct addrinfo hint;
+    struct addrinfo hint = { 0, };
     struct addrinfo *res = NULL;
-    memset (&hint, 0, sizeof hint);
     hint.ai_flags = AI_CANONNAME;
     if (getaddrinfo (host, NULL, &hint, &res) == 0)
       {