upstream nginx-0.7.41 0.7.41
authorDobrica Pavlinusic <dpavlin@rot13.org>
Sat, 21 Mar 2009 17:02:57 +0000 (18:02 +0100)
committerDobrica Pavlinusic <dpavlin@rot13.org>
Sat, 21 Mar 2009 17:02:57 +0000 (18:02 +0100)
nginx/CHANGES
nginx/CHANGES.ru
nginx/src/core/nginx.h
nginx/src/http/modules/perl/nginx.pm
nginx/src/http/ngx_http_core_module.c
nginx/src/http/ngx_http_request.c

index ac86c53..8129db7 100644 (file)
@@ -1,4 +1,12 @@
 
+Changes with nginx 0.7.41                                        11 Mar 2009
+
+    *) Bugfix: a segmentation fault might occur in worker process, if a 
+       "server_name" or a "location" directives had captures in regular 
+       expressions; the issue had appeared in 0.7.40.
+       Thanks to Vladimir Sopot.
+
+
 Changes with nginx 0.7.40                                        09 Mar 2009
 
     *) Feature: the "location" directive supports captures in regular 
index 0f71c6e..575fa6c 100644 (file)
@@ -1,4 +1,12 @@
 
+éÚÍÅÎÅÎÉÑ × nginx 0.7.41                                          11.03.2009
+
+    *) éÓÐÒÁ×ÌÅÎÉÅ: × ÒÁÂÏÞÅÍ ÐÒÏÃÅÓÓÅ ÍÏÇ ÐÒÏÉÚÏÊÔÉ segmentation fault, 
+       ÅÓÌÉ × server_name ÉÌÉ location ÂÙÌÉ ×ÙÄÅÌÅÎÉÑ × ÒÅÇÕÌÑÒÎÙÈ 
+       ×ÙÒÁÖÅÎÉÑÈ; ÏÛÉÂËÁ ÐÏÑ×ÉÌÁÓØ × 0.7.40.
+       óÐÁÓÉÂÏ ÷ÌÁÄÉÍÉÒÕ óÏÐÏÔÕ.
+
+
 éÚÍÅÎÅÎÉÑ × nginx 0.7.40                                          09.03.2009
 
     *) äÏÂÁ×ÌÅÎÉÅ: ÄÉÒÅËÔÉ×Á location ÐÏÄÄÅÒÖÉ×ÁÅÔ ×ÙÄÅÌÅÎÉÑ × ÒÅÇÕÌÑÒÎÙÈ 
index 243712b..2c0406c 100644 (file)
@@ -8,7 +8,7 @@
 #define _NGINX_H_INCLUDED_
 
 
-#define NGINX_VERSION      "0.7.40"
+#define NGINX_VERSION      "0.7.41"
 #define NGINX_VER          "nginx/" NGINX_VERSION
 
 #define NGINX_VAR          "NGINX"
index 350a3d6..a780ee4 100644 (file)
@@ -47,7 +47,7 @@ our @EXPORT = qw(
     HTTP_INSUFFICIENT_STORAGE
 );
 
-our $VERSION = '0.7.40';
+our $VERSION = '0.7.41';
 
 require XSLoader;
 XSLoader::load('nginx', $VERSION);
index ad00946..a2d4e86 100644 (file)
@@ -1380,9 +1380,9 @@ ngx_http_core_find_location(ngx_http_request_t *r)
 
             if ((*clcfp)->captures && r->captures == NULL) {
 
-                len = (NGX_HTTP_MAX_CAPTURES + 1) * 3 * sizeof(int);
+                len = (NGX_HTTP_MAX_CAPTURES + 1) * 3;
 
-                r->captures = ngx_palloc(r->pool, len);
+                r->captures = ngx_palloc(r->pool, len * sizeof(int));
                 if (r->captures == NULL) {
                     return NGX_ERROR;
                 }
index 95a392a..c018d68 100644 (file)
@@ -1662,9 +1662,9 @@ ngx_http_find_virtual_server(ngx_http_request_t *r, u_char *host, size_t len)
 
             if (sn[i].captures && r->captures == NULL) {
 
-                ncaptures = (NGX_HTTP_MAX_CAPTURES + 1) * 3 * sizeof(int);
+                ncaptures = (NGX_HTTP_MAX_CAPTURES + 1) * 3;
 
-                r->captures = ngx_palloc(r->pool, ncaptures);
+                r->captures = ngx_palloc(r->pool, ncaptures * sizeof(int));
                 if (r->captures == NULL) {
                     return NGX_ERROR;
                 }