The official NGINX Open Source repository.
Go to file
Maxim Dounin 00fcc6a987 Copy filter: fixed sendfile aio handlers to set ctx->aio.
Sendfile handlers (aio preload and thread handler) are called within
ctx->output_filter() in ngx_output_chain(), and hence ctx->aio cannot
be set directly in ngx_output_chain().  Meanwhile, it must be set to
make sure loop within ngx_output_chain() will be properly terminated.

There are no known cases that trigger the problem, though in theory
something like aio + sub filter (something that needs body in memory,
and can also free some memory buffers) + sendfile can result in
"task already active" and "second aio post" alerts.

The fix is to set ctx->aio in ngx_http_copy_aio_sendfile_preload()
and ngx_http_copy_thread_handler().

For consistency, ctx->aio is no longer set explicitly in
ngx_output_chain_copy_buf(), as it's now done in
ngx_http_copy_thread_handler().
2016-03-03 21:14:19 +03:00
auto Dynamic modules: perl. 2016-02-26 14:27:04 +03:00
conf Added the REQUEST_SCHEME parameter. 2015-06-05 22:23:26 +03:00
contrib Contrib: add more directives to vim syntax. 2014-10-22 15:31:19 +02:00
docs nginx-1.9.12-RELEASE 2016-02-24 17:53:22 +03:00
misc Updated OpenSSL used for win32 builds. 2016-02-13 07:28:14 +03:00
src Copy filter: fixed sendfile aio handlers to set ctx->aio. 2016-03-03 21:14:19 +03:00
.hgtags release-1.9.12 tag 2016-02-24 17:53:23 +03:00