Mercurial > hg > nginx-vendor-current
comparison src/http/ngx_http_core_module.c @ 376:edf1cb6c328e NGINX_0_7_0
nginx 0.7.0
*) Change: now the 0x00-0x1F, '"' and '\' characters are escaped as
\xXX in an access_log.
Thanks to Maxim Dounin.
*) Change: now nginx allows several "Host" request header line.
*) Feature: the "modified" flag in the "expires" directive.
*) Feature: the $uid_got and $uid_set variables may be used at any
request processing stage.
*) Feature: the $hostname variable.
Thanks to Andrei Nigmatulin.
*) Feature: DESTDIR support.
Thanks to Todd A. Fisher and Andras Voroskoi.
*) Bugfix: a segmentation fault might occur in worker process on Linux,
if keepalive was enabled.
author | Igor Sysoev <http://sysoev.ru> |
---|---|
date | Mon, 19 May 2008 00:00:00 +0400 |
parents | 6639b93e81b2 |
children | 820f6378fc00 |
comparison
equal
deleted
inserted
replaced
375:52f3c9c7eff0 | 376:edf1cb6c328e |
---|---|
2604 ls->conf.rcvbuf = -1; | 2604 ls->conf.rcvbuf = -1; |
2605 ls->conf.sndbuf = -1; | 2605 ls->conf.sndbuf = -1; |
2606 } | 2606 } |
2607 | 2607 |
2608 if (conf->server_name.data == NULL) { | 2608 if (conf->server_name.data == NULL) { |
2609 conf->server_name.data = ngx_palloc(cf->pool, NGX_MAXHOSTNAMELEN); | 2609 conf->server_name = cf->cycle->hostname; |
2610 if (conf->server_name.data == NULL) { | |
2611 return NGX_CONF_ERROR; | |
2612 } | |
2613 | |
2614 if (gethostname((char *) conf->server_name.data, NGX_MAXHOSTNAMELEN) | |
2615 == -1) | |
2616 { | |
2617 ngx_conf_log_error(NGX_LOG_EMERG, cf, ngx_errno, | |
2618 "gethostname() failed"); | |
2619 return NGX_CONF_ERROR; | |
2620 } | |
2621 | |
2622 conf->server_name.len = ngx_strlen(conf->server_name.data); | |
2623 | 2610 |
2624 sn = ngx_array_push(&conf->server_names); | 2611 sn = ngx_array_push(&conf->server_names); |
2625 if (sn == NULL) { | 2612 if (sn == NULL) { |
2626 return NGX_CONF_ERROR; | 2613 return NGX_CONF_ERROR; |
2627 } | 2614 } |
2920 prev->resolver = ngx_resolver_create(cf, NULL); | 2907 prev->resolver = ngx_resolver_create(cf, NULL); |
2921 if (prev->resolver == NULL) { | 2908 if (prev->resolver == NULL) { |
2922 return NGX_CONF_ERROR; | 2909 return NGX_CONF_ERROR; |
2923 } | 2910 } |
2924 } | 2911 } |
2925 | 2912 |
2926 conf->resolver = prev->resolver; | 2913 conf->resolver = prev->resolver; |
2927 } | 2914 } |
2928 | 2915 |
2929 ngx_conf_merge_path_value(conf->client_body_temp_path, | 2916 ngx_conf_merge_path_value(conf->client_body_temp_path, |
2930 prev->client_body_temp_path, | 2917 prev->client_body_temp_path, |
3214 err.data = errstr; | 3201 err.data = errstr; |
3215 | 3202 |
3216 value[i].len--; | 3203 value[i].len--; |
3217 value[i].data++; | 3204 value[i].data++; |
3218 | 3205 |
3219 sn->regex = ngx_regex_compile(&value[i], NGX_REGEX_CASELESS, cf->pool, | 3206 sn->regex = ngx_regex_compile(&value[i], 0, cf->pool, &err); |
3220 &err); | |
3221 | 3207 |
3222 if (sn->regex == NULL) { | 3208 if (sn->regex == NULL) { |
3223 ngx_conf_log_error(NGX_LOG_EMERG, cf, 0, "%s", err.data); | 3209 ngx_conf_log_error(NGX_LOG_EMERG, cf, 0, "%s", err.data); |
3224 return NGX_CONF_ERROR; | 3210 return NGX_CONF_ERROR; |
3225 } | 3211 } |