diff options
author | Max Romanov <max.romanov@nginx.com> | 2017-07-07 16:01:34 +0300 |
---|---|---|
committer | Max Romanov <max.romanov@nginx.com> | 2017-07-07 16:01:34 +0300 |
commit | 74cda90e31f97ba0ebd6483f2b073c1240b93a58 (patch) | |
tree | 69727640f476822e3cc1e40ac09bf645251617be /src/nxt_process.c | |
parent | 61008a7c0b45fe55f3f611c61f81e569e6baee30 (diff) | |
download | unit-74cda90e31f97ba0ebd6483f2b073c1240b93a58.tar.gz unit-74cda90e31f97ba0ebd6483f2b073c1240b93a58.tar.bz2 |
Process stop notification from master to all other processes.
New port message type introduced NXT_PORT_MSG_REMOVE_PID. Default handler
removes process description from nxt_runtime_t with all ports, incoming and
outgoing mmaps etc.
Diffstat (limited to 'src/nxt_process.c')
-rw-r--r-- | src/nxt_process.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/nxt_process.c b/src/nxt_process.c index 33af310d..97b51c4e 100644 --- a/src/nxt_process.c +++ b/src/nxt_process.c @@ -46,6 +46,8 @@ nxt_process_create(nxt_task_t *task, nxt_process_t *process) process->pid = nxt_pid; process->init->port->pid = nxt_pid; + rt->types = 0; + nxt_runtime_process_add(rt, process); nxt_process_start(task, process->init); @@ -94,7 +96,7 @@ nxt_process_start(nxt_task_t *task, nxt_process_init_t *process) thread = task->thread; rt = thread->runtime; - rt->type = process->type; + rt->types |= (1U << process->type); engine = thread->engine; |