comparison src/http/ngx_http.c @ 302:9b7db0df50f0 NGINX_0_5_21

nginx 0.5.21 *) Bugfix: if server has more than about ten locations, then regex locations might be choosen not in that order as they were specified. *) Bugfix: a worker process may got caught in an endless loop on 64-bit platform, if the 33-rd or next in succession backend has failed. Thanks to Anton Povarov. *) Bugfix: a bus error might occur on Solaris/sparc64 if the PCRE library was used. Thanks to Andrei Nigmatulin. *) Bugfix: in the HTTPS protocol in the "proxy_pass" directive.
author Igor Sysoev <http://sysoev.ru>
date Mon, 28 May 2007 00:00:00 +0400
parents 500a3242dff6
children 94e16de3c33f
comparison
equal deleted inserted replaced
301:a025840de07d 302:9b7db0df50f0
17 static ngx_int_t ngx_http_add_names(ngx_conf_t *cf, 17 static ngx_int_t ngx_http_add_names(ngx_conf_t *cf,
18 ngx_http_conf_in_addr_t *in_addr, ngx_http_core_srv_conf_t *cscf); 18 ngx_http_conf_in_addr_t *in_addr, ngx_http_core_srv_conf_t *cscf);
19 static char *ngx_http_merge_locations(ngx_conf_t *cf, 19 static char *ngx_http_merge_locations(ngx_conf_t *cf,
20 ngx_array_t *locations, void **loc_conf, ngx_http_module_t *module, 20 ngx_array_t *locations, void **loc_conf, ngx_http_module_t *module,
21 ngx_uint_t ctx_index); 21 ngx_uint_t ctx_index);
22 static int ngx_libc_cdecl ngx_http_cmp_conf_in_addrs(const void *one, 22 static int ngx_http_cmp_conf_in_addrs(const void *one, const void *two);
23 const void *two);
24 static int ngx_libc_cdecl ngx_http_cmp_dns_wildcards(const void *one, 23 static int ngx_libc_cdecl ngx_http_cmp_dns_wildcards(const void *one,
25 const void *two); 24 const void *two);
26 25
27 ngx_uint_t ngx_http_max_module; 26 ngx_uint_t ngx_http_max_module;
28 27
597 /* AF_INET only */ 596 /* AF_INET only */
598 597
599 in_port = in_ports.elts; 598 in_port = in_ports.elts;
600 for (p = 0; p < in_ports.nelts; p++) { 599 for (p = 0; p < in_ports.nelts; p++) {
601 600
602 ngx_qsort(in_port[p].addrs.elts, (size_t) in_port[p].addrs.nelts, 601 ngx_sort(in_port[p].addrs.elts, (size_t) in_port[p].addrs.nelts,
603 sizeof(ngx_http_conf_in_addr_t), ngx_http_cmp_conf_in_addrs); 602 sizeof(ngx_http_conf_in_addr_t), ngx_http_cmp_conf_in_addrs);
604 603
605 /* 604 /*
606 * check whether all name-based servers have the same configuraiton 605 * check whether all name-based servers have the same configuraiton
607 * as the default server, 606 * as the default server,
608 * or some servers disable optimizing the server names 607 * or some servers disable optimizing the server names
1025 1024
1026 return NGX_CONF_OK; 1025 return NGX_CONF_OK;
1027 } 1026 }
1028 1027
1029 1028
1030 static int ngx_libc_cdecl 1029 static int
1031 ngx_http_cmp_conf_in_addrs(const void *one, const void *two) 1030 ngx_http_cmp_conf_in_addrs(const void *one, const void *two)
1032 { 1031 {
1033 ngx_http_conf_in_addr_t *first, *second; 1032 ngx_http_conf_in_addr_t *first, *second;
1034 1033
1035 first = (ngx_http_conf_in_addr_t *) one; 1034 first = (ngx_http_conf_in_addr_t *) one;