summaryrefslogtreecommitdiff
path: root/src/svc_auth_des.c
diff options
context:
space:
mode:
authorJoshua Kinard <kumba@gentoo.org>2017-08-23 14:31:36 -0400
committerSteve Dickson <steved@redhat.com>2017-08-23 14:32:56 -0400
commit5356b63005e9d8169e0399cb76f26fbd29a78dee (patch)
tree8f400a06bd6fe31bf1a6e985a8f4353d36194b6b /src/svc_auth_des.c
parentccc63fec27c84209f15fb34279acbe7cb6a7fe1c (diff)
downloadti-rpc-5356b63005e9d8169e0399cb76f26fbd29a78dee.tar.gz
Replace bzero() calls with equivalent memset() calls
As annotated in the bzero(3) man page, bzero() was marked as LEGACY in POSIX.1-2001 and removed in POSIX.1-2008, and should be replaced with memset() calls to write zeros to a memory region. The attached patch replaces two bzero() calls and one __bzero() call in libtirpc with equivalent memset() calls. The latter replacement fixes a compile error under uclibc-ng, which lacks a definition for __bzero() Signed-off-by: Joshua Kinard <kumba@gentoo.org> Signed-off-by: Steve Dickson <steved@redhat.com>
Diffstat (limited to 'src/svc_auth_des.c')
-rw-r--r--src/svc_auth_des.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/svc_auth_des.c b/src/svc_auth_des.c
index 2e90146..19a7c60 100644
--- a/src/svc_auth_des.c
+++ b/src/svc_auth_des.c
@@ -356,7 +356,7 @@ cache_init()
authdes_cache = (struct cache_entry *)
mem_alloc(sizeof(struct cache_entry) * AUTHDES_CACHESZ);
- bzero((char *)authdes_cache,
+ memset(authdes_cache, 0,
sizeof(struct cache_entry) * AUTHDES_CACHESZ);
authdes_lru = (short *)mem_alloc(sizeof(short) * AUTHDES_CACHESZ);