1 .\" This page was taken from the 4.4BSD-Lite CDROM (BSD license)
3 .\" @(#)bindresvport.3n 2.2 88/08/02 4.0 RPCSRC; from 1.7 88/03/14 SMI
4 .TH BINDRESVPORT 3 1987-11-22
6 bindresvport \- bind a socket to a privileged IP port
9 .B #include <sys/types.h>
10 .B #include <netinet/in.h>
12 .BI "int bindresvport(int " sd ", struct sockaddr_in **" sin );
17 is used to bind a socket descriptor to a privileged
20 port number in the range 0-1023.
21 The routine returns 0 if it is successful,
22 otherwise \-1 is returned and
24 set to reflect the cause of the error.
26 Only root can bind to a privileged port; this call will fail for any