Lines Matching defs:socket

26 #include <sys/socket.h>
52 #include <isc/socket.h>
121 * allowable socket file descriptor.
159 * bug: DP_POLL ioctl could keep sleeping even if socket I/O is possible for
162 * as follows: the socket watcher is first initialized with the state of
163 * "poll_idle". While it's in the idle state it keeps sleeping until a socket
164 * event occurs. When it wakes up for a socket I/O event, it moves to the
207 * Some systems define the socket length argument as an int, some as size_t,
254 * IPv6 control information. If the socket is an IPv6 socket we want
293 /* Locked by socket lock. */
319 listener : 1, /* listener socket */
582 "socket %p: %s", sock, msgbuf);
587 "socket %p %s: %s", sock, peerbuf, msgbuf);
625 * Increment socket-related statistics counters.
751 * socket for the other operation.
796 * This is a wakeup on a socket. If the socket is not in the
819 * closing the socket, hoping it doesn't leave dangling state in
842 * a socket will make the application dysfunctional, but there
1027 * Process control messages received on a socket.
1723 * socket is UDP or TCP. If it is UDP, some errors
1767 * Caller must ensure that the socket is not locked and no external
1776 * No one has this socket open, so the watcher doesn't have to be
1777 * poked, and the socket doesn't have to be locked.
1788 * The caller may close the socket once this function returns,
1789 * and `fd' may be reassigned for a new socket. So we do
1990 * count be 1, and that the magic number is valid. The other socket bits,
1993 * also close the socket.
2030 * the kernel to issue a warning about us using a deprecated socket option.
2093 const char *err = "socket";
2106 sock->fd = socket(sock->pf, SOCK_DGRAM, IPPROTO_UDP);
2109 sock->fd = socket(sock->pf, SOCK_STREAM, IPPROTO_TCP);
2112 sock->fd = socket(sock->pf, SOCK_STREAM, 0);
2154 "socket: file descriptor exceeds limit (%d/%u)",
2366 * Create a new 'type' socket managed by 'manager'. Events
2368 * called with 'arg' as the arg value. The new socket is returned
2415 * Note we don't have to lock the socket like we normally would because
2455 * this socket.
2487 * Create a new 'type' socket managed by 'manager'. Events
2489 * called with 'arg' as the arg value. The new socket is returned
2519 * Note we don't have to lock the socket like we normally would because
2549 * Attach to a socket. Caller must explicitly detach when it is done.
2564 * Dereference a socket. If this is the last reference to it, clean things
2565 * up by destroying the socket.
2630 * I/O is possible on a given socket. Schedule an event to this task that
2635 * The socket and manager must be locked before calling this function.
2717 * before the manager got the socket lock?
2726 sock->references++; /* keep socket around for this internal event */
2746 sock->references++; /* keep socket around for this internal event */
2755 * Dequeue an item off the given socket's read queue, set the result code
2760 * asked to, send and detach from the socket as well.
2762 * Caller must have the socket locked if the event is attached to the socket.
2785 * Caller must have the socket locked if the event is attached to the socket.
2807 * Call accept() on a socket, to get the new file descriptor. The listen
2808 * socket is used as a prototype to create a new isc_socket_t. The new
2809 * socket has one outstanding reference. The task receiving the event
2837 "internal_accept called, locked socket");
2847 sock->references--; /* the internal event is done with this socket */
2856 * If it is empty, unlock the socket and return.
2866 * EAGAIN or EINTR, simply poke the watcher to watch this socket
2999 * -1 means the new socket didn't happen.
3032 "accepted connection, new socket %p",
3083 sock->references--; /* the internal event is done with this socket */
3091 * Try to do as much I/O as possible on this socket. There are no
3137 * Find out what socket this is and lock it.
3151 sock->references--; /* the internal event is done with this socket */
3159 * Try to do as much I/O as possible on this socket. There are no
3192 * Find out what socket this is and lock it.
3211 sock->references--; /* the internal event is done with this socket */
3232 * Find out what socket this is and lock it.
3251 sock->references--; /* the internal event is done with this socket */
3278 * If the socket is going to be closed, don't do more I/O.
3493 "for socket %d"), msg, fd);
3511 * This is a wakeup on a socket. Look
3659 * Create a new socket manager.
4078 * Destroy a socket manager.
4207 * Attach to socket and to task
4218 * Enqueue the request. If the socket was previously not being
4413 * Enqueue the request. If the socket was previously
4610 "isc_socket_cleanunix: %s: not a socket",
4624 s = socket(AF_UNIX, SOCK_STREAM, 0);
4629 "isc_socket_cleanunix: socket(%s): %s",
4652 "isc_socket_cleanunix: %s: not a socket",
4845 * Set up to listen on a given socket. We do this by creating an internal
4846 * event that will be dispatched when the socket has read activity. The
4910 * actual ev_sender will be touched up to be the socket.
4929 * Attach to socket and to task.
4946 * Poke watcher here. We still have the socket locked, so there
5007 * HP-UX "fails" to connect a UDP socket and sets errno to
5010 * at the time of sending a packet on the socket.
5090 * Poke watcher here. We still have the socket locked, so there
5104 * Called when a socket with a pending connect() finishes.
5126 * to keep the socket around for us. Decrement the count here.
5278 * Run through the list of events on this socket, and cancel the ones
5538 isc_socket_setname(isc_socket_t *socket, const char *name, void *tag) {
5541 * Name 'socket'.
5544 REQUIRE(VALID_SOCKET(socket));
5546 LOCK(&socket->lock);
5547 memset(socket->name, 0, sizeof(socket->name));
5548 strncpy(socket->name, name, sizeof(socket->name) - 1);
5549 socket->tag = tag;
5550 UNLOCK(&socket->lock);
5554 isc_socket_getname(isc_socket_t *socket) {
5555 return (socket->name);
5559 isc_socket_gettag(isc_socket_t *socket) {
5560 return (socket->tag);
5602 TRY0(xmlTextWriterStartElement(writer, ISC_XMLCHAR "socket"));
5673 TRY0(xmlTextWriterEndElement(writer)); /* socket */