comparison src/http/ngx_http.c @ 410:a094317ba307 NGINX_0_7_14

nginx 0.7.14 *) Change: now the ssl_certificate and ssl_certificate_key directives have not default values. *) Feature: the "listen" directive supports the "ssl" parameter. *) Feature: now nginx takes into account a time zone change while reconfiguration on FreeBSD and Linux. *) Bugfix: the "listen" directive parameters such as "backlog", "rcvbuf", etc. were not set, if a default server was not the first one. *) Bugfix: if URI part captured by a "rewrite" directive was used as a query string, then the query string was not escaped. *) Bugfix: configuration file validity test improvements.
author Igor Sysoev <http://sysoev.ru>
date Mon, 01 Sep 2008 00:00:00 +0400
parents 349057ecf4d5
children 79c5df00501e
comparison
equal deleted inserted replaced
409:d46814b99ca0 410:a094317ba307
1156 return NGX_ERROR; 1156 return NGX_ERROR;
1157 } 1157 }
1158 1158
1159 in_addr[a].core_srv_conf = cscfp[s]; 1159 in_addr[a].core_srv_conf = cscfp[s];
1160 in_addr[a].default_server = 1; 1160 in_addr[a].default_server = 1;
1161 #if (NGX_HTTP_SSL)
1162 in_addr[a].ssl = listen[l].conf.ssl;
1163 #endif
1164 in_addr[a].listen_conf = &listen[l].conf;
1161 } 1165 }
1162 1166
1163 goto found; 1167 goto found;
1164 } 1168 }
1165 1169
1239 in_addr->regex = NULL; 1243 in_addr->regex = NULL;
1240 #endif 1244 #endif
1241 in_addr->core_srv_conf = cscf; 1245 in_addr->core_srv_conf = cscf;
1242 in_addr->default_server = listen->conf.default_server; 1246 in_addr->default_server = listen->conf.default_server;
1243 in_addr->bind = listen->conf.bind; 1247 in_addr->bind = listen->conf.bind;
1248 #if (NGX_HTTP_SSL)
1249 in_addr->ssl = listen->conf.ssl;
1250 #endif
1244 in_addr->listen_conf = &listen->conf; 1251 in_addr->listen_conf = &listen->conf;
1245
1246 #if (NGX_DEBUG)
1247 {
1248 u_char text[20];
1249 ngx_inet_ntop(AF_INET, &in_addr->addr, text, 20);
1250 ngx_log_debug2(NGX_LOG_DEBUG_HTTP, cf->log, 0, "address: %s:%d",
1251 text, in_port->port);
1252 }
1253 #endif
1254 1252
1255 return ngx_http_add_names(cf, cscf, in_addr); 1253 return ngx_http_add_names(cf, cscf, in_addr);
1256 } 1254 }
1257 1255
1258 1256
1654 1652
1655 for (i = 0; i < hip->naddrs; i++) { 1653 for (i = 0; i < hip->naddrs; i++) {
1656 hip->addrs[i].addr = in_addr[i].addr; 1654 hip->addrs[i].addr = in_addr[i].addr;
1657 hip->addrs[i].core_srv_conf = in_addr[i].core_srv_conf; 1655 hip->addrs[i].core_srv_conf = in_addr[i].core_srv_conf;
1658 1656
1657 #if (NGX_HTTP_SSL)
1658 hip->addrs[i].ssl = in_addr[i].ssl;
1659 #endif
1660
1659 if (in_addr[i].hash.buckets == NULL 1661 if (in_addr[i].hash.buckets == NULL
1660 && (in_addr[i].wc_head == NULL 1662 && (in_addr[i].wc_head == NULL
1661 || in_addr[i].wc_head->hash.buckets == NULL) 1663 || in_addr[i].wc_head->hash.buckets == NULL)
1662 && (in_addr[i].wc_head == NULL 1664 && (in_addr[i].wc_head == NULL
1663 || in_addr[i].wc_head->hash.buckets == NULL)) 1665 || in_addr[i].wc_head->hash.buckets == NULL))
1785 1787
1786 if (prev_types_hash->buckets == NULL) { 1788 if (prev_types_hash->buckets == NULL) {
1787 1789
1788 if (prev_keys == NULL) { 1790 if (prev_keys == NULL) {
1789 1791
1790 if (ngx_http_set_default_types(cf, &prev_keys, default_types) 1792 if (ngx_http_set_default_types(cf, &prev_keys, default_types)
1791 != NGX_OK) 1793 != NGX_OK)
1792 { 1794 {
1793 return NGX_CONF_ERROR; 1795 return NGX_CONF_ERROR;
1794 } 1796 }
1795 } 1797 }
1796 1798
1797 hash.hash = prev_types_hash; 1799 hash.hash = prev_types_hash;
1798 hash.key = NULL; 1800 hash.key = NULL;
1799 hash.max_size = 2048; 1801 hash.max_size = 2048;