summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorIgor Sysoev <igor@sysoev.ru>2007-07-09 06:57:19 +0000
committerJonathan Kolb <jon@b0g.us>2007-07-09 06:57:19 +0000
commitafcc42e81ad255426aa89ccf01786b19a5230b08 (patch)
tree57c6dda7f843f86b245b12b947083b1c97f4ad67
parentd1dd84060ba0825ca9e224a22b34bcc0a9ce0752 (diff)
downloadnginx-afcc42e81ad255426aa89ccf01786b19a5230b08.tar.gz
Changes with nginx 0.5.27 09 Jul 2007v0.5.27
*) Bugfix: if remote SSI subrequest was used, then posterior local file subrequest might transferred to client in wrong order. *) Bugfix: large SSI inclusions buffered in temporary files were truncated.
-rw-r--r--CHANGES9
-rw-r--r--CHANGES.ru10
-rw-r--r--src/core/nginx.h2
-rw-r--r--src/http/modules/ngx_http_fastcgi_module.c12
-rw-r--r--src/http/modules/ngx_http_ssi_filter_module.c10
-rw-r--r--src/http/modules/perl/nginx.pm2
-rw-r--r--src/http/ngx_http_copy_filter_module.c4
-rw-r--r--src/http/ngx_http_upstream.c13
8 files changed, 50 insertions, 12 deletions
diff --git a/CHANGES b/CHANGES
index 7f9476093..2c1d195f0 100644
--- a/CHANGES
+++ b/CHANGES
@@ -1,4 +1,13 @@
+Changes with nginx 0.5.27 09 Jul 2007
+
+ *) Bugfix: if remote SSI subrequest was used, then posterior local file
+ subrequest might transferred to client in wrong order.
+
+ *) Bugfix: large SSI inclusions buffered in temporary files were
+ truncated.
+
+
Changes with nginx 0.5.26 17 Jun 2007
*) Bugfix: in SSI parsing.
diff --git a/CHANGES.ru b/CHANGES.ru
index c3c90c853..035cfc252 100644
--- a/CHANGES.ru
+++ b/CHANGES.ru
@@ -1,4 +1,14 @@
+Изменения в nginx 0.5.27 09.07.2007
+
+ *) Исправление: при использовании удалённого подзапроса в SSI
+ последующий подзапрос локального файла мог отдаваться клиенту в
+ неверном порядке.
+
+ *) Исправление: большие включения в SSI, сохранённые во временные
+ файлы, передавались не полностью.
+
+
Изменения в nginx 0.5.26 17.06.2007
*) Исправление: в парсинге SSI.
diff --git a/src/core/nginx.h b/src/core/nginx.h
index 991c7be55..7507acec1 100644
--- a/src/core/nginx.h
+++ b/src/core/nginx.h
@@ -8,7 +8,7 @@
#define _NGINX_H_INCLUDED_
-#define NGINX_VERSION "0.5.26"
+#define NGINX_VERSION "0.5.27"
#define NGINX_VER "nginx/" NGINX_VERSION
#define NGINX_VAR "NGINX"
diff --git a/src/http/modules/ngx_http_fastcgi_module.c b/src/http/modules/ngx_http_fastcgi_module.c
index 6daf6ce39..2e592824a 100644
--- a/src/http/modules/ngx_http_fastcgi_module.c
+++ b/src/http/modules/ngx_http_fastcgi_module.c
@@ -1144,16 +1144,16 @@ ngx_http_fastcgi_process_header(ngx_http_request_t *r)
return NGX_OK;
}
- if (u->buffer.pos == u->buffer.last) {
+ if (rc == NGX_OK) {
return NGX_AGAIN;
}
- if (rc == NGX_AGAIN) {
- ngx_log_error(NGX_LOG_ALERT, r->connection->log, 0,
- "upstream split a header line in FastCGI records");
+ /* rc == NGX_AGAIN */
- return NGX_HTTP_UPSTREAM_INVALID_HEADER;
- }
+ ngx_log_error(NGX_LOG_ALERT, r->connection->log, 0,
+ "upstream split a header line in FastCGI records");
+
+ return NGX_HTTP_UPSTREAM_INVALID_HEADER;
}
}
diff --git a/src/http/modules/ngx_http_ssi_filter_module.c b/src/http/modules/ngx_http_ssi_filter_module.c
index 5343ca0be..549ae4ce2 100644
--- a/src/http/modules/ngx_http_ssi_filter_module.c
+++ b/src/http/modules/ngx_http_ssi_filter_module.c
@@ -800,8 +800,14 @@ ngx_http_ssi_body_filter(ngx_http_request_t *r, ngx_chain_t *in)
}
}
- if (cmd->flush && ctx->out) {
- rc = ngx_http_ssi_output(r, ctx);
+ if (cmd->flush) {
+
+ if (ctx->out) {
+ rc = ngx_http_ssi_output(r, ctx);
+
+ } else {
+ rc = ngx_http_next_body_filter(r, NULL);
+ }
if (rc == NGX_ERROR) {
return NGX_ERROR;
diff --git a/src/http/modules/perl/nginx.pm b/src/http/modules/perl/nginx.pm
index 550cf1f3e..f59fd4377 100644
--- a/src/http/modules/perl/nginx.pm
+++ b/src/http/modules/perl/nginx.pm
@@ -47,7 +47,7 @@ our @EXPORT = qw(
HTTP_INSUFFICIENT_STORAGE
);
-our $VERSION = '0.5.26';
+our $VERSION = '0.5.27';
require XSLoader;
XSLoader::load('nginx', $VERSION);
diff --git a/src/http/ngx_http_copy_filter_module.c b/src/http/ngx_http_copy_filter_module.c
index c96dbfa76..3069779c2 100644
--- a/src/http/ngx_http_copy_filter_module.c
+++ b/src/http/ngx_http_copy_filter_module.c
@@ -117,6 +117,10 @@ ngx_http_copy_filter(ngx_http_request_t *r, ngx_chain_t *in)
r->buffered |= NGX_HTTP_COPY_BUFFERED;
}
+ if (r != r->main) {
+ r->out = ctx->in;
+ }
+
#if (NGX_DEBUG)
ngx_log_debug3(NGX_LOG_DEBUG_HTTP, r->connection->log, 0,
"copy filter: %i \"%V?%V\"", rc, &r->uri, &r->args);
diff --git a/src/http/ngx_http_upstream.c b/src/http/ngx_http_upstream.c
index 392783664..c1bae266c 100644
--- a/src/http/ngx_http_upstream.c
+++ b/src/http/ngx_http_upstream.c
@@ -2157,8 +2157,17 @@ ngx_http_upstream_finalize_request(ngx_http_request_t *r,
r->connection->log->action = "sending to client";
- if (rc == 0 && r == r->main && !r->post_action) {
- rc = ngx_http_send_special(r, NGX_HTTP_LAST);
+ if (rc == 0) {
+ if (r == r->main) {
+ if (!r->post_action) {
+ rc = ngx_http_send_special(r, NGX_HTTP_LAST);
+ }
+
+ } else {
+ if (r->out) {
+ rc = NGX_AGAIN;
+ }
+ }
}
ngx_http_finalize_request(r, rc);