Lines Matching refs:fd

26 nxt_inline void nxt_port_close_fds(nxt_fd_t *fd);
122 nxt_socket_close(port->socket.task, port->socket.fd); in nxt_port_destroy()
130 port->socket.fd = port->pair[1]; in nxt_port_write_enable()
161 nxt_fd_t fd, nxt_fd_t fd2, uint32_t stream, nxt_port_id_t reply_port, in nxt_port_socket_write2() argument
178 msg.fd[0] = fd; in nxt_port_socket_write2()
179 msg.fd[1] = fd2; in nxt_port_socket_write2()
194 if (fd == -1 && nxt_port_can_enqueue_buf(b)) { in nxt_port_socket_write2()
206 (int) port->pid, (int) port->id, port->socket.fd, in nxt_port_socket_write2()
233 (int) port->pid, (int) port->id, port->socket.fd, in nxt_port_socket_write2()
446 n = nxt_socketpair_send(&port->socket, msg->fd, iov, sb.niov + 1); in nxt_port_write_handler()
451 port->socket.fd, n, sb.size + iov[0].iov_len); in nxt_port_write_handler()
461 nxt_debug(task, "port %d: frag stream #%uD", port->socket.fd, in nxt_port_write_handler()
468 msg->fd[0] = -1; in nxt_port_write_handler()
469 msg->fd[1] = -1; in nxt_port_write_handler()
598 nxt_port_close_fds(msg->fd); in nxt_port_msg_close_fd()
603 nxt_port_close_fds(nxt_fd_t *fd) in nxt_port_close_fds() argument
605 if (fd[0] != -1) { in nxt_port_close_fds()
606 nxt_fd_close(fd[0]); in nxt_port_close_fds()
607 fd[0] = -1; in nxt_port_close_fds()
610 if (fd[1] != -1) { in nxt_port_close_fds()
611 nxt_fd_close(fd[1]); in nxt_port_close_fds()
612 fd[1] = -1; in nxt_port_close_fds()
705 port->socket.fd = port->pair[0]; in nxt_port_read_enable()
761 msg.fd[0] = -1; in nxt_port_read_handler()
762 msg.fd[1] = -1; in nxt_port_read_handler()
764 ret = nxt_socket_msg_oob_get(&oob, msg.fd, in nxt_port_read_handler()
768 port->socket.fd); in nxt_port_read_handler()
770 nxt_port_close_fds(msg.fd); in nxt_port_read_handler()
852 (int) port->pid, (int) port->id, port->socket.fd, in nxt_port_queue_read_handler()
859 (int) port->pid, (int) port->id, port->socket.fd, in nxt_port_queue_read_handler()
867 msg.fd[0] = smsg->fd[0]; in nxt_port_queue_read_handler()
868 msg.fd[1] = smsg->fd[1]; in nxt_port_queue_read_handler()
875 (int) port->pid, (int) port->id, port->socket.fd, in nxt_port_queue_read_handler()
913 msg.fd[0] = -1; in nxt_port_queue_read_handler()
914 msg.fd[1] = -1; in nxt_port_queue_read_handler()
916 ret = nxt_socket_msg_oob_get(&oob, msg.fd, in nxt_port_queue_read_handler()
920 port->socket.fd); in nxt_port_queue_read_handler()
922 nxt_port_close_fds(msg.fd); in nxt_port_queue_read_handler()
934 (int) port->pid, (int) port->id, port->socket.fd, in nxt_port_queue_read_handler()
941 (int) port->pid, (int) port->id, port->socket.fd, in nxt_port_queue_read_handler()
947 (int) port->pid, (int) port->id, port->socket.fd, in nxt_port_queue_read_handler()
960 port->socket.fd); in nxt_port_queue_read_handler()
972 port->socket.fd); in nxt_port_queue_read_handler()
981 smsg->fd[0] = msg.fd[0]; in nxt_port_queue_read_handler()
982 smsg->fd[1] = msg.fd[1]; in nxt_port_queue_read_handler()
1179 port->socket.fd, msg->size); in nxt_port_read_msg_process()
1181 nxt_port_close_fds(msg->fd); in nxt_port_read_msg_process()
1221 msg->fd[0] = fmsg->fd[0]; in nxt_port_read_msg_process()
1222 msg->fd[1] = fmsg->fd[1]; in nxt_port_read_msg_process()
1256 msg->fd[0] = -1; in nxt_port_read_msg_process()
1257 msg->fd[1] = -1; in nxt_port_read_msg_process()
1261 nxt_port_close_fds(msg->fd); in nxt_port_read_msg_process()