Home
last modified time | relevance | path

Searched refs:pair (Results 1 – 14 of 14) sorted by relevance

/unit/src/
H A Dnxt_socketpair.c24 nxt_socketpair_create(nxt_task_t *task, nxt_socket_t *pair) in nxt_socketpair_create() argument
31 nxt_debug(task, "socketpair(): %d:%d", pair[0], pair[1]); in nxt_socketpair_create()
33 if (nxt_slow_path(nxt_socket_nonblocking(task, pair[0]) != NXT_OK)) { in nxt_socketpair_create()
37 if (nxt_slow_path(fcntl(pair[0], F_SETFD, FD_CLOEXEC) == -1)) { in nxt_socketpair_create()
45 if (nxt_slow_path(fcntl(pair[1], F_SETFD, FD_CLOEXEC) == -1)) { in nxt_socketpair_create()
52 if (nxt_slow_path(setsockopt(pair[0], SOL_SOCKET, SO_PASSCRED, in nxt_socketpair_create()
59 if (nxt_slow_path(setsockopt(pair[1], SOL_SOCKET, SO_PASSCRED, in nxt_socketpair_create()
71 nxt_socketpair_close(task, pair); in nxt_socketpair_create()
78 nxt_socketpair_close(nxt_task_t *task, nxt_socket_t *pair) in nxt_socketpair_close() argument
80 nxt_socket_close(task, pair[0]); in nxt_socketpair_close()
[all …]
H A Dnxt_external.c89 rc = nxt_external_fd_no_cloexec(task, proto_port->pair[1]); in nxt_external_start()
94 rc = nxt_external_fd_no_cloexec(task, router_port->pair[1]); in nxt_external_start()
99 rc = nxt_external_fd_no_cloexec(task, my_port->pair[0]); in nxt_external_start()
104 rc = nxt_external_fd_no_cloexec(task, my_port->pair[1]); in nxt_external_start()
129 proto_port->pid, proto_port->id, proto_port->pair[1], in nxt_external_start()
130 router_port->pid, router_port->id, router_port->pair[1], in nxt_external_start()
131 my_port->pid, my_port->id, my_port->pair[0], in nxt_external_start()
132 my_port->pair[1], in nxt_external_start()
H A Dnxt_port.c31 nxt_assert(port->pair[0] == -1); in nxt_port_mp_cleanup()
32 nxt_assert(port->pair[1] == -1); in nxt_port_mp_cleanup()
95 if (port->pair[0] != -1) { in nxt_port_close()
98 nxt_fd_close(port->pair[0]); in nxt_port_close()
99 port->pair[0] = -1; in nxt_port_close()
102 if (port->pair[1] != -1) { in nxt_port_close()
103 nxt_fd_close(port->pair[1]); in nxt_port_close()
104 port->pair[1] = -1; in nxt_port_close()
242 new_port->pair[1], port->pid); in nxt_port_send_port()
296 port->pair[0] = -1; in nxt_port_new_port_handler()
[all …]
H A Dnxt_socket.h113 nxt_socket_t *pair);
114 NXT_EXPORT void nxt_socketpair_close(nxt_task_t *task, nxt_socket_t *pair);
H A Dnxt_port_socket.c49 port->pair[0] = -1; in nxt_port_socket_init()
50 port->pair[1] = -1; in nxt_port_socket_init()
56 snd = port->pair[1]; in nxt_port_socket_init()
63 rcv = port->pair[0]; in nxt_port_socket_init()
110 nxt_socket_close(task, port->pair[0]); in nxt_port_socket_init()
111 nxt_socket_close(task, port->pair[1]); in nxt_port_socket_init()
130 port->socket.fd = port->pair[1]; in nxt_port_write_enable()
145 nxt_socket_close(port->socket.task, port->pair[1]); in nxt_port_write_close()
146 port->pair[1] = -1; in nxt_port_write_close()
705 port->socket.fd = port->pair[0]; in nxt_port_read_enable()
[all …]
H A Dnxt_application.c1041 init->ready_port.out_fd = proto_port->pair[1]; in nxt_unit_default_init()
1048 init->router_port.out_fd = router_port->pair[1]; in nxt_unit_default_init()
1052 init->read_port.in_fd = my_port->pair[0]; in nxt_unit_default_init()
1053 init->read_port.out_fd = my_port->pair[1]; in nxt_unit_default_init()
H A Dnxt_port.h257 nxt_socket_t pair[2]; member
H A Dnxt_port_rpc.c129 nxt_assert(port->pair[0] != -1); in nxt_port_rpc_register_handler_ex()
H A Dnxt_main_process.c656 port->pair[0] = -1; in nxt_main_process_whoami_handler()
657 port->pair[1] = msg->fd[0]; in nxt_main_process_whoami_handler()
H A Dnxt_process.c514 fd = (process->parent_port != main_port) ? my_port->pair[1] : -1; in nxt_process_whoami()
H A Dnxt_router.c446 port_fd = app->shared_port->pair[0]; in nxt_router_start_app_process_handler()
2805 port_fd = app->shared_port->pair[0]; in nxt_router_app_rpc_create()
4818 if (main_app_port->pair[1] != -1 && main_app_port->app_link.next == NULL) { in nxt_router_app_port_release()
4826 if (main_app_port->pair[1] != -1 in nxt_router_app_port_release()
4864 if (main_app_port->pair[1] == -1) { in nxt_router_app_port_release()
/unit/src/nodejs/unit-http/
H A Dwebsocket_request.js221 pairs.forEach(function(pair) { argument
222 var eq_idx = pair.indexOf('=');
225 name: pair,
231 var key = pair.substr(0, eq_idx).trim();
232 var val = pair.substr(++eq_idx, pair.length).trim();
/unit/src/python/
H A Dnxt_python_asgi.c740 PyObject *pair, *v; in nxt_py_asgi_create_address() local
742 pair = PyTuple_New(2); in nxt_py_asgi_create_address()
743 if (nxt_slow_path(pair == NULL)) { in nxt_py_asgi_create_address()
752 Py_DECREF(pair); in nxt_py_asgi_create_address()
757 PyTuple_SET_ITEM(pair, 0, v); in nxt_py_asgi_create_address()
768 Py_DECREF(pair); in nxt_py_asgi_create_address()
773 PyTuple_SET_ITEM(pair, 1, v); in nxt_py_asgi_create_address()
775 return pair; in nxt_py_asgi_create_address()
/unit/auto/
H A Dsockets136 int pair[2];
138 if (socketpair(AF_UNIX, SOCK_SEQPACKET, 0, pair) != 0)