summaryrefslogtreecommitdiff
path: root/lib/libc
diff options
context:
space:
mode:
authorTheo de Raadt <deraadt@cvs.openbsd.org>1996-07-22 03:44:43 +0000
committerTheo de Raadt <deraadt@cvs.openbsd.org>1996-07-22 03:44:43 +0000
commit1c4a4843bea81a61fc93d91651086edf188aeb2a (patch)
treec9068229e99632d3322711cda8107e797c5787bd /lib/libc
parente29fc77cc89e7eecab332b2c5967f1dd598a6fae (diff)
bzero sockaddr before use
Diffstat (limited to 'lib/libc')
-rw-r--r--lib/libc/net/rcmd.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/lib/libc/net/rcmd.c b/lib/libc/net/rcmd.c
index 214cd2792a4..5796364cc68 100644
--- a/lib/libc/net/rcmd.c
+++ b/lib/libc/net/rcmd.c
@@ -220,6 +220,7 @@ rresvport(alport)
struct sockaddr_in sin;
int s;
+ bzero(&sin, sizeof sin);
sin.sin_len = sizeof(struct sockaddr_in);
sin.sin_family = AF_INET;
sin.sin_addr.s_addr = INADDR_ANY;