comparison src/os/unix/ngx_linux_init.c @ 16:74b1868dd3cd NGINX_0_1_8

nginx 0.1.8 *) Bugfix: in the ngx_http_autoindex_module if the long file names were in the listing. *) Feature: the "^~" modifier in the location directive. *) Feature: the proxy_max_temp_file_size directive.
author Igor Sysoev <http://sysoev.ru>
date Sat, 20 Nov 2004 00:00:00 +0300
parents cc9f381affaa
children 6f8b0dc0f8dd
comparison
equal deleted inserted replaced
15:0503cb60c4e4 16:74b1868dd3cd
28 }; 28 };
29 29
30 30
31 ngx_int_t ngx_os_init(ngx_log_t *log) 31 ngx_int_t ngx_os_init(ngx_log_t *log)
32 { 32 {
33 int name[2]; 33 int name[2];
34 size_t len; 34 size_t len;
35 ngx_err_t err;
35 36
36 name[0] = CTL_KERN; 37 name[0] = CTL_KERN;
37 name[1] = KERN_OSTYPE; 38 name[1] = KERN_OSTYPE;
38 len = sizeof(ngx_linux_kern_ostype); 39 len = sizeof(ngx_linux_kern_ostype);
39 if (sysctl(name, sizeof(name), ngx_linux_kern_ostype, &len, NULL, 0) 40 if (sysctl(name, sizeof(name), ngx_linux_kern_ostype, &len, NULL, 0)
56 57
57 name[0] = CTL_KERN; 58 name[0] = CTL_KERN;
58 name[1] = KERN_RTSIGMAX; 59 name[1] = KERN_RTSIGMAX;
59 len = sizeof(ngx_linux_rtsig_max); 60 len = sizeof(ngx_linux_rtsig_max);
60 if (sysctl(name, sizeof(name), &ngx_linux_rtsig_max, &len, NULL, 0) == -1) { 61 if (sysctl(name, sizeof(name), &ngx_linux_rtsig_max, &len, NULL, 0) == -1) {
61 ngx_log_error(NGX_LOG_INFO, log, ngx_errno, 62 err = ngx_errno;
62 "sysctl(KERN_RTSIGMAX) failed"); 63
64 if (err != NGX_ENOTDIR) {
65 ngx_log_error(NGX_LOG_ALERT, log, err,
66 "sysctl(KERN_RTSIGMAX) failed");
67
68 return NGX_ERROR;
69 }
70
63 ngx_linux_rtsig_max = 0; 71 ngx_linux_rtsig_max = 0;
64
65 } 72 }
66 73
67 ngx_init_setproctitle(log); 74 ngx_init_setproctitle(log);
68 75
69 76