From 418fff7e8f3d4906eabc0efa5a14989defc33ae4 Mon Sep 17 00:00:00 2001 From: Matthew Dillon Date: Sat, 13 Oct 2001 17:20:51 +0000 Subject: [PATCH] Add warning about zeroing-out the socket structure before populating it. --- lib/libc/sys/bind.2 | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/lib/libc/sys/bind.2 b/lib/libc/sys/bind.2 index 3f9d70776a0..4e99aa883a0 100644 --- a/lib/libc/sys/bind.2 +++ b/lib/libc/sys/bind.2 @@ -64,6 +64,10 @@ needed (using .Pp The rules used in address binding vary between communication domains. Consult the manual entries in section 4 for detailed information. +.Pp +For maximum portability, you should always zero-out the socket structure +before populating it, before passing it to +.Fn bind . .Sh IMPLEMENTATION NOTES In the non-threaded library .Fn bind