Skip to content

Commit

Permalink
Merge pull request alibaba#416 from cfsego/tengine-2.0.1
Browse files Browse the repository at this point in the history
merged changes between nginx-1.4.5 and nginx-1.4.6
  • Loading branch information
yaoweibin committed Mar 6, 2014
2 parents 1ddce00 + 916049e commit a3c97fc
Show file tree
Hide file tree
Showing 7 changed files with 44 additions and 11 deletions.
11 changes: 11 additions & 0 deletions CHANGES
Original file line number Diff line number Diff line change
@@ -1,4 +1,15 @@

Changes with nginx 1.4.6 04 Mar 2014

*) Bugfix: the "client_max_body_size" directive might not work when
reading a request body using chunked transfer encoding; the bug had
appeared in 1.3.9.
Thanks to Lucas Molas.

*) Bugfix: a segmentation fault might occur in a worker process when
proxying WebSocket connections.


Changes with nginx 1.4.5 11 Feb 2014

*) Bugfix: the $ssl_session_id variable contained full session
Expand Down
5 changes: 3 additions & 2 deletions CHANGES.cn
Original file line number Diff line number Diff line change
@@ -1,14 +1,15 @@
Tengine 2.0.1 [2014-02-28]
Tengine 2.0.1 [2014-03-06]
* Feature: 请求体不缓存的机制支持chunked输入 [yaoweibin]
* Feature: trim模块支持更多规则,支持根据变量启用 [taoyuanyuan]
* Feature: 利用/etc/resolv.conf自动配置resolver [lifeibo, yaoweibin]
* Feature: 增加$ascii_变量前缀,可以生成任意ASCII字符 [yzprofile]
* Feature: 增加"image_filter_crop_offset"指令 [lax]
* Change: 合并nginx-1.4.5版本的修改 [chobits]
* Change: 合并截至nginx-1.4.6版本的所有修改 [chobits, cfsego]
* Bugfix: 修正使用长连接进行健康检查时报错的问题 [lilbedwin]
* Bugfix: 修正使用WebSocket时nginx崩溃的问题
http://trac.nginx.org/nginx/ticket/503 [Hao Chen]
* Bugfix: 减少nginx处理大文件时的内存消耗 [cfsego]
* Bugfix: 在未设置URI时,禁用跳转到named locations的重定向

Tengine 2.0.0 [2014-01-08]
* Feature: 增强DSO模块,编译动态模块不再依赖原始编译环境 [monadbobo]
Expand Down
11 changes: 11 additions & 0 deletions CHANGES.ru
Original file line number Diff line number Diff line change
@@ -1,4 +1,15 @@

Изменения в nginx 1.4.6 04.03.2014

*) Исправление: директива client_max_body_size могла не работать при
чтении тела запроса с использованием chunked transfer encoding;
ошибка появилась в 1.3.9.
Спасибо Lucas Molas.

*) Исправление: при проксировании WebSocket-соединений в рабочем
процессе мог произойти segmentation fault.


Изменения в nginx 1.4.5 11.02.2014

*) Исправление: переменная $ssl_session_id содержала всю сессию в
Expand Down
8 changes: 5 additions & 3 deletions CHANGES.te
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
Changes with Tengine 2.0.1 28 Feb 2014
Changes with Tengine 2.0.1 06 March 2014

*) Feature: now non-buffering request body mechanism supports chunked input.
(yaoweibin)
Expand All @@ -14,17 +14,19 @@ Changes with Tengine 2.0.1 28 Feb 2014

*) Feature: added a new directive "image_filter_crop_offset". (lax)

*) Change: merged changes between nginx-1.4.4 and nginx-1.4.5. (chobits)
*) Change: merged changes between nginx-1.4.4 and nginx-1.4.6. (chobits, cfsego)

*) Bugfix: upstream health check will not fail on error when using
keep-alive connections. (lilbedwin)

*) Bugfix: nginx crushed when upstream rejected nginx WebSocket connection.
*) Bugfix: nginx crashed when upstream rejected nginx WebSocket connection.
http://trac.nginx.org/nginx/ticket/503 (Hao Chen)

*) Bugfix: reduce nginx memory consumption when processing large files.
(cfsego)

*) Bugfix: disabled redirects to named locations if URI is not set.


Changes with Tengine 2.0.0 08 Jan 2014

Expand Down
4 changes: 2 additions & 2 deletions src/core/nginx.h
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,8 @@
#define _NGINX_H_INCLUDED_


#define nginx_version 1004005
#define NGINX_VERSION "1.4.5"
#define nginx_version 1004006
#define NGINX_VERSION "1.4.6"
#define NGINX_VER "nginx/" NGINX_VERSION

#define TENGINE "Tengine"
Expand Down
8 changes: 8 additions & 0 deletions src/http/ngx_http_core_module.c
Original file line number Diff line number Diff line change
Expand Up @@ -2756,6 +2756,14 @@ ngx_http_named_location(ngx_http_request_t *r, ngx_str_t *name)
return NGX_DONE;
}

if (r->uri.len == 0) {
ngx_log_error(NGX_LOG_ERR, r->connection->log, 0,
"empty URI in redirect to named location \"%V\"", name);

ngx_http_finalize_request(r, NGX_HTTP_INTERNAL_SERVER_ERROR);
return NGX_DONE;
}

cscf = ngx_http_get_module_srv_conf(r, ngx_http_core_module);

if (cscf->named_locations) {
Expand Down
8 changes: 4 additions & 4 deletions src/http/ngx_http_request_body.c
Original file line number Diff line number Diff line change
Expand Up @@ -1521,13 +1521,13 @@ ngx_http_request_body_chunked_filter(ngx_http_request_t *r, ngx_chain_t *in)

if (clcf->client_max_body_size
&& clcf->client_max_body_size
< r->headers_in.content_length_n + rb->chunked->size)
- r->headers_in.content_length_n < rb->chunked->size)
{
ngx_log_error(NGX_LOG_ERR, r->connection->log, 0,
"client intended to send too large chunked "
"body: %O bytes",
r->headers_in.content_length_n
+ rb->chunked->size);
"body: %O+%O bytes",
r->headers_in.content_length_n,
rb->chunked->size);

r->lingering_close = 1;

Expand Down

0 comments on commit a3c97fc

Please sign in to comment.