summaryrefslogtreecommitdiff
path: root/src/http/modules
diff options
context:
space:
mode:
authorIgor Sysoev <igor@sysoev.ru>2009-07-13 11:48:05 +0000
committerJonathan Kolb <jon@b0g.us>2009-07-13 11:48:05 +0000
commitccb71228cbec260e8921e698a34c57da5b0693cd (patch)
tree6b30300e4456fc749fb0f5d39087c592c33356cd /src/http/modules
parent83116b3fea0173c4fdc4993c757869f92fb9d799 (diff)
downloadnginx-ccb71228cbec260e8921e698a34c57da5b0693cd.tar.gz
Changes with nginx 0.8.5 13 Jul 2009v0.8.5
*) Bugfix: now nginx allows underscores in a request method. *) Bugfix: a 500 error code was returned for invalid login/password while HTTP Basic authentication on Windows. *) Bugfix: ngx_http_perl_module responses did not work in subrequests. *) Bugfix: in ngx_http_limit_req_module. Thanks to Maxim Dounin.
Diffstat (limited to 'src/http/modules')
-rw-r--r--src/http/modules/ngx_http_limit_req_module.c19
-rw-r--r--src/http/modules/perl/nginx.pm2
2 files changed, 18 insertions, 3 deletions
diff --git a/src/http/modules/ngx_http_limit_req_module.c b/src/http/modules/ngx_http_limit_req_module.c
index 2a07c74e5..84e70b4f4 100644
--- a/src/http/modules/ngx_http_limit_req_module.c
+++ b/src/http/modules/ngx_http_limit_req_module.c
@@ -181,7 +181,7 @@ ngx_http_limit_req_handler(ngx_http_request_t *r)
}
ngx_log_debug3(NGX_LOG_DEBUG_HTTP, r->connection->log, 0,
- "limit_req: %i %ui.%03ui", rc, excess / 1000, excess % 1000);
+ "limit_req: %i %ui.%03ui", rc, excess / 1000, excess % 1000);
if (rc == NGX_BUSY) {
ngx_shmtx_unlock(&ctx->shpool->mutex);
@@ -263,8 +263,23 @@ done:
static void
ngx_http_limit_req_delay(ngx_http_request_t *r)
{
+ ngx_event_t *wev;
+
ngx_log_debug0(NGX_LOG_DEBUG_HTTP, r->connection->log, 0,
- "limit_req delay");
+ "limit_req delay");
+
+ wev = r->connection->write;
+
+ if (!wev->timedout) {
+
+ if (ngx_handle_write_event(wev, 0) != NGX_OK) {
+ ngx_http_finalize_request(r, NGX_HTTP_INTERNAL_SERVER_ERROR);
+ }
+
+ return;
+ }
+
+ wev->timedout = 0;
if (ngx_handle_read_event(r->connection->read, 0) != NGX_OK) {
ngx_http_finalize_request(r, NGX_HTTP_INTERNAL_SERVER_ERROR);
diff --git a/src/http/modules/perl/nginx.pm b/src/http/modules/perl/nginx.pm
index 3bb73cce1..317cf2459 100644
--- a/src/http/modules/perl/nginx.pm
+++ b/src/http/modules/perl/nginx.pm
@@ -47,7 +47,7 @@ our @EXPORT = qw(
HTTP_INSUFFICIENT_STORAGE
);
-our $VERSION = '0.8.4';
+our $VERSION = '0.8.5';
require XSLoader;
XSLoader::load('nginx', $VERSION);