about summary refs log tree commit diff
path: root/sunrpc/svcauth_des.c
diff options
context:
space:
mode:
authorUlrich Drepper <drepper@redhat.com>2006-05-05 16:18:45 +0000
committerUlrich Drepper <drepper@redhat.com>2006-05-05 16:18:45 +0000
commitcdb9c32138fe80cc4767b5c597713cf773e12f0e (patch)
treee57fee5bcb50042464adb7d4331e46359d04e96f /sunrpc/svcauth_des.c
parentfff04b32afcf55edd678f7635a70f8918c4a0bd9 (diff)
downloadglibc-cdb9c32138fe80cc4767b5c597713cf773e12f0e.tar.gz
glibc-cdb9c32138fe80cc4767b5c597713cf773e12f0e.tar.xz
glibc-cdb9c32138fe80cc4767b5c597713cf773e12f0e.zip
* sunrpc/svcauth_des.c (cache_init): Use calloc instead of
	malloc&bzero.

	* sunrpc/svc_udp.c (BZERO): Remove definition.
	(CALLOC): Define.
	(svc_enablecache): Use CALLOC instead of ALLOC&BZERO.

	* sunrpc/des_impl.c: Remove ALT_ECB support.  We never used it.
	(des_SPtrans): Use uint32_t type.
	(des_skb): Likewise.

	* sunrpc/xdr_ref.c (xdr_reference): Use calloc instead of malloc&bzero.

	place where the iso639 array might be accessed beyond the limits.
Diffstat (limited to 'sunrpc/svcauth_des.c')
-rw-r--r--sunrpc/svcauth_des.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/sunrpc/svcauth_des.c b/sunrpc/svcauth_des.c
index becdd5066d..933d001341 100644
--- a/sunrpc/svcauth_des.c
+++ b/sunrpc/svcauth_des.c
@@ -396,11 +396,9 @@ cache_init (void)
   register int i;
 
   authdes_cache = (struct cache_entry *)
-    mem_alloc (sizeof (struct cache_entry) * AUTHDES_CACHESZ);
+    calloc (sizeof (struct cache_entry) * AUTHDES_CACHESZ, 1);
   if (authdes_cache == NULL)
     return;
-  __bzero ((char *) authdes_cache,
-	   sizeof (struct cache_entry) * AUTHDES_CACHESZ);
 
   authdes_lru = (int *) mem_alloc (sizeof (int) * AUTHDES_CACHESZ);
   /*