From the NannyMUD documentation

LAST CHANGE

2001-10-02

FUNCTION


NAME

        socket_bind - Bind a name to a socket.

SYNTAX

        #include 
        #include 

        int socket_bind(int s, int port)

DESCRIPTION

        socket_bind() assigns a name to an unnamed socket. When a
        socket is created with socket_create it exists in a name space
        (address family) but has no name assigned. socket_bind()
        requests that the port be assigned to the socket s.

        RETURN VALUE
        socket_bind() returns:

        EESUCCESS    on success.

        a negative value indicated below on error.

	ERRORS
        EEFDRANGE      Descriptor out of range.
        EEBADF         Descriptor is invalid.
        EESECURITY     Security violation attempted.
        EEISBOUND      Socket is already bound.
        EEADDRINUSE    Address already in use.
        EEBIND         Problem with bind.
        EEGETSOCKNAME  Problem with getsockname.

SEE ALSO

        socket_connect in efun/socket/socket_connect

SEE ALSO

        socket_create in efun/socket/socket_create
        socket_create in efun/socket/socket_create

SEE ALSO

        socket_listen in efun/socket/socket_listen