* @brief Binds a socket to a specific local address and port. * * This function assigns a local address to a socket, defined by the 'name' parameter. * The address allows the socket to receive data sent to this address. * * @param s The file descriptor of the socket to bind. * @param name A pointer to a 'sockaddr' structure that specifies the address to bind to. *
| 118 | * @see accept() Accepts connections on a bound and listening socket. |
| 119 | */ |
| 120 | int bind(int s, const struct sockaddr *name, socklen_t namelen) |
| 121 | { |
| 122 | int socket = dfs_net_getsocket(s); |
| 123 | |
| 124 | return sal_bind(socket, name, namelen); |
| 125 | } |
| 126 | RTM_EXPORT(bind); |
| 127 | |
| 128 | /** |