# HG changeset patch # User Maxim Dounin # Date 1374749687 -14400 # Node ID 819c5b53d8b51ebaab1d4e6ccd2063662ff740b4 # Parent d47ef93134e5fcb954fb985580cbb0c2b2540d2b Sub filter: flush buffers handling. diff -r d47ef93134e5 -r 819c5b53d8b5 src/http/modules/ngx_http_sub_filter_module.c --- a/src/http/modules/ngx_http_sub_filter_module.c Thu Jul 25 14:54:45 2013 +0400 +++ b/src/http/modules/ngx_http_sub_filter_module.c Thu Jul 25 14:54:47 2013 +0400 @@ -369,7 +369,9 @@ continue; } - if (ctx->buf->last_buf || ngx_buf_in_memory(ctx->buf)) { + if (ctx->buf->last_buf || ctx->buf->flush + || ngx_buf_in_memory(ctx->buf)) + { if (b == NULL) { cl = ngx_chain_get_free_buf(r->pool, &ctx->free); if (cl == NULL) { @@ -387,6 +389,7 @@ } b->last_buf = ctx->buf->last_buf; + b->flush = ctx->buf->flush; b->shadow = ctx->buf; b->recycled = ctx->buf->recycled;