Mercurial > hg > nginx-vendor-0-8
diff src/http/modules/ngx_http_ssi_filter_module.c @ 244:500a3242dff6 NGINX_0_4_7
nginx 0.4.7
*) Feature: the ngx_http_flv_module.
*) Feature: the $request_body_file variable.
*) Feature: the "charset" and "source_charset" directives support the
variables.
*) Bugfix: if an "include" SSI command were before another "include"
SSI command with an "wait" parameter, then the "wait" parameter
might not work.
*) Bugfix: if the "proxy_buffering off" directive was used or while
working with memcached the connections might not be closed on
timeout.
*) Bugfix: nginx did not run on 64-bit platforms except amd64, sparc64,
and ppc64.
author | Igor Sysoev <http://sysoev.ru> |
---|---|
date | Tue, 10 Oct 2006 00:00:00 +0400 |
parents | c982febb7588 |
children | b52bd034c577 |
line wrap: on
line diff
--- a/src/http/modules/ngx_http_ssi_filter_module.c +++ b/src/http/modules/ngx_http_ssi_filter_module.c @@ -417,10 +417,11 @@ ngx_http_ssi_body_filter(ngx_http_reques return NGX_AGAIN; } - ngx_log_debug1(NGX_LOG_DEBUG_HTTP, r->connection->log, 0, - "http ssi filter \"%V\" continue", &r->uri); - - ctx->wait = 0; + if (ctx->wait == r) { + ngx_log_debug1(NGX_LOG_DEBUG_HTTP, r->connection->log, 0, + "http ssi filter \"%V\" continue", &r->uri); + ctx->wait = NULL; + } } slcf = ngx_http_get_module_loc_conf(r, ngx_http_ssi_filter_module); @@ -1814,6 +1815,7 @@ ngx_http_ssi_include(ngx_http_request_t ngx_buf_t *b; ngx_uint_t flags, i; ngx_chain_t *out, *cl, *tl, **ll; + ngx_http_request_t *sr; ngx_http_ssi_ctx_t *mctx; ngx_http_ssi_block_t *bl; @@ -1936,7 +1938,7 @@ ngx_http_ssi_include(ngx_http_request_t } } - rc = ngx_http_subrequest(r, uri, &args, out, flags); + rc = ngx_http_subrequest(r, uri, &args, &sr, out, flags); if (rc == NGX_ERROR) { return NGX_HTTP_SSI_ERROR; @@ -1947,7 +1949,13 @@ ngx_http_ssi_include(ngx_http_request_t } if (rc == NGX_AGAIN) { - ctx->wait = 1; + if (ctx->wait == NULL) { + ctx->wait = sr; + + } else { + ngx_log_error(NGX_LOG_ERR, r->connection->log, 0, + "only one subrequest may be waited at the same time"); + } } return rc;