mirror of
https://github.com/nginx/nginx.git
synced 2026-08-27 20:25:32 +00:00
file AIO read may be posted inside loop
This commit is contained in:
parent
7087d5d72a
commit
89eae52df8
2 changed files with 7 additions and 6 deletions
|
|
@ -74,18 +74,18 @@ ngx_output_chain(ngx_output_chain_ctx_t *ctx, ngx_chain_t *in)
|
|||
}
|
||||
}
|
||||
|
||||
#if (NGX_HAVE_FILE_AIO)
|
||||
if (ctx->aio) {
|
||||
return NGX_AGAIN;
|
||||
}
|
||||
#endif
|
||||
|
||||
out = NULL;
|
||||
last_out = &out;
|
||||
last = NGX_NONE;
|
||||
|
||||
for ( ;; ) {
|
||||
|
||||
#if (NGX_HAVE_FILE_AIO)
|
||||
if (ctx->aio) {
|
||||
return NGX_AGAIN;
|
||||
}
|
||||
#endif
|
||||
|
||||
while (ctx->in) {
|
||||
|
||||
/*
|
||||
|
|
|
|||
|
|
@ -211,6 +211,7 @@ ngx_http_copy_aio_handler(ngx_output_chain_ctx_t *ctx, ngx_file_t *file)
|
|||
|
||||
r->main->blocked++;
|
||||
r->aio = 1;
|
||||
ctx->aio = 1;
|
||||
}
|
||||
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue