Lines Matching refs:socket
41 # include <sys/socket.h>
307 /* Create the socket of the family appropriate for the address. */
308 sock = socket (sa->sa_family, SOCK_STREAM, 0);
342 /* Bind the client side of the socket to the requested
353 /* Connect the socket to the remote endpoint. */
362 DEBUGP (("Created socket %d.\n", sock));
437 /* Create a socket, bind it to local interface BIND_ADDRESS on port
438 *PORT, set up a listen backlog, and return the resulting socket, or
442 NULL, the socket is bound to the default address. PORT should
447 Calling accept() on such a socket waits for and accepts incoming
462 sock = socket (bind_address->family, SOCK_STREAM, 0);
477 DEBUGP (("Local socket fd %d bound.\n", sock));
485 /* If we can't find out the socket's local address ("name"),
486 something is seriously wrong with the socket, and it's
507 return the new socket used for communication with the client.
534 DEBUGP (("Accepted client at socket %d.\n", sock));
542 (client) side of the socket. Else if ENDPOINT is ENDPOINT_PEER, it
543 returns the address of the remote (peer's) side of the socket. */
674 reading. This is because, when the connection closes, the socket
707 /* Basic socket operations, mostly EINTR wrappers. */
767 /* Reading and writing from the network. We build around the socket
787 sockets. FD should otherwise be a real socket, on which you can
979 per socket, so that particular optimization wouldn't work. */