comparison src/os/unix/ngx_process.c @ 26:45fe5b98a9de NGINX_0_1_13

nginx 0.1.13 *) Feature: the server_names_hash and server_names_hash_threshold directives. *) Bugfix: the *.domain.tld names in the "server_name" directive did not work. *) Bugfix: the %request_length log parameter logged the incorrect length.
author Igor Sysoev <http://sysoev.ru>
date Tue, 21 Dec 2004 00:00:00 +0300
parents 46833bd150cb
children 72eb30262aac
comparison
equal deleted inserted replaced
25:21488c53e135 26:45fe5b98a9de
140 140
141 default: 141 default:
142 break; 142 break;
143 } 143 }
144 144
145 ngx_log_debug2(NGX_LOG_DEBUG_CORE, cycle->log, 0, 145 ngx_log_error(NGX_LOG_NOTICE, cycle->log, 0, "start %s %P", name, pid);
146 "spawn %s: %P", name, pid);
147 146
148 ngx_processes[s].pid = pid; 147 ngx_processes[s].pid = pid;
149 ngx_processes[s].exited = 0; 148 ngx_processes[s].exited = 0;
150 149
151 if (respawn >= 0) { 150 if (respawn >= 0) {
214 ngx_pid_t pid; 213 ngx_pid_t pid;
215 ngx_err_t err; 214 ngx_err_t err;
216 ngx_int_t i; 215 ngx_int_t i;
217 ngx_uint_t one; 216 ngx_uint_t one;
218 struct timeval tv; 217 struct timeval tv;
218
219 one = 0; 219 one = 0;
220 220
221 for ( ;; ) { 221 for ( ;; ) {
222 pid = waitpid(-1, &status, WNOHANG); 222 pid = waitpid(-1, &status, WNOHANG);
223 223
285 "%s %P exited on signal %d%s", 285 "%s %P exited on signal %d%s",
286 process, pid, WTERMSIG(status), 286 process, pid, WTERMSIG(status),
287 WCOREDUMP(status) ? " (core dumped)" : ""); 287 WCOREDUMP(status) ? " (core dumped)" : "");
288 288
289 } else { 289 } else {
290 ngx_log_error(NGX_LOG_INFO, ngx_cycle->log, 0, 290 ngx_log_error(NGX_LOG_NOTICE, ngx_cycle->log, 0,
291 "%s %P exited with code %d", 291 "%s %P exited with code %d",
292 process, pid, WEXITSTATUS(status)); 292 process, pid, WEXITSTATUS(status));
293 } 293 }
294 294
295 if (WEXITSTATUS(status) == 2 && ngx_processes[i].respawn) { 295 if (WEXITSTATUS(status) == 2 && ngx_processes[i].respawn) {