comparison src/os/unix/ngx_process.c @ 452:23fb87bddda1 release-0.1.1

nginx-0.1.1-RELEASE import *) Feature: the gzip_types directive. *) Feature: the tcp_nodelay directive. *) Feature: the send_lowat directive is working not only on OSes that support kqueue NOTE_LOWAT, but also on OSes that support SO_SNDLOWAT. *) Feature: the setproctitle() emulation for Linux and Solaris. *) Bugfix: the "Location" header rewrite bug fixed while the proxying. *) Bugfix: the ngx_http_chunked_module module may get caught in an endless loop. *) Bugfix: the /dev/poll module bugs fixed. *) Bugfix: the responses were corrupted when the temporary files were used while the proxying. *) Bugfix: the unescaped requests were passed to the backend. *) Bugfix: while the build configuration on Linux 2.4 the --with-poll_module parameter was required.
author Igor Sysoev <igor@sysoev.ru>
date Mon, 11 Oct 2004 15:07:03 +0000
parents 42d11f017717
children 295d97d70c69
comparison
equal deleted inserted replaced
451:f40362e47689 452:23fb87bddda1
10 #include <ngx_channel.h> 10 #include <ngx_channel.h>
11 11
12 12
13 static void ngx_execute_proc(ngx_cycle_t *cycle, void *data); 13 static void ngx_execute_proc(ngx_cycle_t *cycle, void *data);
14 14
15 ngx_int_t ngx_process_slot; 15
16 ngx_socket_t ngx_channel; 16 int ngx_argc;
17 ngx_int_t ngx_last_process; 17 char **ngx_argv;
18 ngx_process_t ngx_processes[NGX_MAX_PROCESSES]; 18 char **ngx_os_argv;
19
20 ngx_int_t ngx_process_slot;
21 ngx_socket_t ngx_channel;
22 ngx_int_t ngx_last_process;
23 ngx_process_t ngx_processes[NGX_MAX_PROCESSES];
19 24
20 25
21 ngx_pid_t ngx_spawn_process(ngx_cycle_t *cycle, 26 ngx_pid_t ngx_spawn_process(ngx_cycle_t *cycle,
22 ngx_spawn_proc_pt proc, void *data, 27 ngx_spawn_proc_pt proc, void *data,
23 char *name, ngx_int_t respawn) 28 char *name, ngx_int_t respawn)
229 234
230 if (err == NGX_ECHILD && one) { 235 if (err == NGX_ECHILD && one) {
231 return; 236 return;
232 } 237 }
233 238
239 #if (SOLARIS)
240
241 /*
242 * Solaris always calls the signal handler for each exited process
243 * despite waitpid() may be already called for this process
244 */
245
246 if (err == NGX_ECHILD) {
247 ngx_log_error(NGX_LOG_INFO, ngx_cycle->log, errno,
248 "waitpid() failed");
249 }
250
251 #endif
252
234 ngx_log_error(NGX_LOG_ALERT, ngx_cycle->log, errno, 253 ngx_log_error(NGX_LOG_ALERT, ngx_cycle->log, errno,
235 "waitpid() failed"); 254 "waitpid() failed");
255
236 return; 256 return;
237 } 257 }
238 258
239 259
240 if (ngx_accept_mutex_ptr) { 260 if (ngx_accept_mutex_ptr) {