comparison src/core/ngx_output_chain.c @ 3776:7450029ff51e

file AIO read may be posted inside loop
author Igor Sysoev <igor@sysoev.ru>
date Tue, 12 Oct 2010 12:06:52 +0000
parents 76d252724db5
children 5db098f97e0e 4919fb357a5d
comparison
equal deleted inserted replaced
3775:2902fc8487ae 3776:7450029ff51e
72 if (ngx_output_chain_add_copy(ctx->pool, &ctx->in, in) == NGX_ERROR) { 72 if (ngx_output_chain_add_copy(ctx->pool, &ctx->in, in) == NGX_ERROR) {
73 return NGX_ERROR; 73 return NGX_ERROR;
74 } 74 }
75 } 75 }
76 76
77 #if (NGX_HAVE_FILE_AIO)
78 if (ctx->aio) {
79 return NGX_AGAIN;
80 }
81 #endif
82
83 out = NULL; 77 out = NULL;
84 last_out = &out; 78 last_out = &out;
85 last = NGX_NONE; 79 last = NGX_NONE;
86 80
87 for ( ;; ) { 81 for ( ;; ) {
82
83 #if (NGX_HAVE_FILE_AIO)
84 if (ctx->aio) {
85 return NGX_AGAIN;
86 }
87 #endif
88 88
89 while (ctx->in) { 89 while (ctx->in) {
90 90
91 /* 91 /*
92 * cycle while there are the ctx->in bufs 92 * cycle while there are the ctx->in bufs