diff options
author | 1996-07-29 06:15:29 +0000 | |
---|---|---|
committer | 1996-07-29 06:15:29 +0000 | |
commit | e3bf207f4c4ef6de8b80222caf84c03a981ae68a (patch) | |
tree | 339cfd888d91ae20e0f6a4630f3dc8e43231a972 /lib/libc/net/rcmd.c | |
parent | Use new bind() kernel semantics. (diff) | |
download | wireguard-openbsd-e3bf207f4c4ef6de8b80222caf84c03a981ae68a.tar.xz wireguard-openbsd-e3bf207f4c4ef6de8b80222caf84c03a981ae68a.zip |
ensure bindresvport() is told to find a port
Diffstat (limited to 'lib/libc/net/rcmd.c')
-rw-r--r-- | lib/libc/net/rcmd.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/lib/libc/net/rcmd.c b/lib/libc/net/rcmd.c index 28420d20ebe..643604f3b30 100644 --- a/lib/libc/net/rcmd.c +++ b/lib/libc/net/rcmd.c @@ -235,6 +235,7 @@ rresvport(alport) (void)close(s); return (-1); } + sin.sin_port = 0; if (bindresvport(s, &sin) == -1) { (void)close(s); return (-1); |