]> git.kaiwu.me - nginx.git/commitdiff
fix request counter for rewrite or internal redirection cycle,
authorIgor Sysoev <igor@sysoev.ru>
Thu, 10 Sep 2009 16:34:09 +0000 (16:34 +0000)
committerIgor Sysoev <igor@sysoev.ru>
Thu, 10 Sep 2009 16:34:09 +0000 (16:34 +0000)
the bug was introduced in r3050

src/http/ngx_http_core_module.c

index f99b91031296a89f40f51dcd657d164eb38c9820..3abb0ed3f136ad511c41ddf23189cf1091bf9000 100644 (file)
@@ -994,6 +994,7 @@ ngx_http_core_post_rewrite_phase(ngx_http_request_t *r,
                       "rewrite or internal redirection cycle "
                       "while processing \"%V\"", &r->uri);
 
+        r->main->count++;
         ngx_http_finalize_request(r, NGX_HTTP_INTERNAL_SERVER_ERROR);
         return NGX_OK;
     }
@@ -2172,6 +2173,7 @@ ngx_http_internal_redirect(ngx_http_request_t *r,
                       "rewrite or internal redirection cycle "
                       "while internal redirect to \"%V\"", uri);
 
+        r->main->count++;
         ngx_http_finalize_request(r, NGX_HTTP_INTERNAL_SERVER_ERROR);
         return NGX_DONE;
     }