diff 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
line wrap: on
line diff
--- a/src/core/ngx_output_chain.c
+++ b/src/core/ngx_output_chain.c
@@ -74,18 +74,18 @@ ngx_output_chain(ngx_output_chain_ctx_t 
         }
     }
 
-#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) {
 
             /*