comparison src/http/modules/ngx_http_referer_module.c @ 570:8246d8a2c2be NGINX_0_8_37

nginx 0.8.37 *) Feature: the ngx_http_split_clients_module. *) Feature: the "map" directive supports keys more than 255 characters. *) Bugfix: nginx ignored the "private" and "no-store" values in the "Cache-Control" backend response header line. *) Bugfix: a "stub" parameter of an "include" SSI directive was not used, if empty response has 200 status code. *) Bugfix: if a proxied or FastCGI request was internally redirected to another proxied or FastCGI location, then a segmentation fault might occur in a worker process; the bug had appeared in 0.8.33. Thanks to Yichun Zhang. *) Bugfix: IMAP connections may hang until they timed out while talking to Zimbra server. Thanks to Alan Batie.
author Igor Sysoev <http://sysoev.ru>
date Mon, 17 May 2010 00:00:00 +0400
parents da3c99095432
children ad6fee8052d7
comparison
equal deleted inserted replaced
569:19b134bf21c0 570:8246d8a2c2be
361 ngx_uint_t i, n; 361 ngx_uint_t i, n;
362 ngx_http_variable_t *var; 362 ngx_http_variable_t *var;
363 ngx_http_server_name_t *sn; 363 ngx_http_server_name_t *sn;
364 ngx_http_core_srv_conf_t *cscf; 364 ngx_http_core_srv_conf_t *cscf;
365 365
366 name.len = sizeof("invalid_referer") - 1; 366 ngx_str_set(&name, "invalid_referer");
367 name.data = (u_char *) "invalid_referer";
368 367
369 var = ngx_http_add_variable(cf, &name, 368 var = ngx_http_add_variable(cf, &name,
370 NGX_HTTP_VAR_CHANGEABLE|NGX_HTTP_VAR_NOHASH); 369 NGX_HTTP_VAR_CHANGEABLE|NGX_HTTP_VAR_NOHASH);
371 if (var == NULL) { 370 if (var == NULL) {
372 return NGX_CONF_ERROR; 371 return NGX_CONF_ERROR;
405 if (ngx_strcmp(value[i].data, "blocked") == 0) { 404 if (ngx_strcmp(value[i].data, "blocked") == 0) {
406 rlcf->blocked_referer = 1; 405 rlcf->blocked_referer = 1;
407 continue; 406 continue;
408 } 407 }
409 408
410 uri.len = 0; 409 ngx_str_null(&uri);
411 uri.data = NULL;
412 410
413 if (ngx_strcmp(value[i].data, "server_names") == 0) { 411 if (ngx_strcmp(value[i].data, "server_names") == 0) {
414 412
415 cscf = ngx_http_conf_get_module_srv_conf(cf, ngx_http_core_module); 413 cscf = ngx_http_conf_get_module_srv_conf(cf, ngx_http_core_module);
416 414