Clear the buffer before calling the SIOCGIFCONF ioctl. This makes
authorTheodore Tso <tytso@mit.edu>
Wed, 13 Sep 1995 23:02:18 +0000 (23:02 +0000)
committerTheodore Tso <tytso@mit.edu>
Wed, 13 Sep 1995 23:02:18 +0000 (23:02 +0000)
purify happy.

git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@6782 dc483132-0cff-0310-8789-dd5450dbe970

src/lib/crypto/os/ChangeLog
src/lib/crypto/os/c_localaddr.c

index 1c42e522841543d475c97eab23362de1d954a269..78cda02df5f57ac1ce6be8457e82c9c96b96f3da 100644 (file)
@@ -1,3 +1,9 @@
+Wed Sep 13 17:32:36 1995  Theodore Y. Ts'o  <tytso@dcl>
+
+       * c_localaddr.c (krb5_crypto_os_localaddr): Clear the buffer
+               before calling the SIOCGIFCONF ioctl.  This makes purify
+               happy.
+
 Thu Sep  7 12:00:00 1995  James Mattly <mattly@fusion.com>
        
        * Renamed ustime.c to c_ustime.c
index 7ab153a8a79fb120febb4573fb2ea431b29adc06..c1d75cf70ca10ca11dad43921fb6240fd7bbe29e 100644 (file)
@@ -117,9 +117,10 @@ krb5_crypto_os_localaddr(addr)
     int n_found;
     int mem_err = 0;
     
+    memset(buf, 0, sizeof(buf));
     ifc.ifc_len = sizeof(buf);
     ifc.ifc_buf = buf;
-
+    
     s = socket (USE_AF, USE_TYPE, USE_PROTO);
     if (s < 0)
        return errno;