diff options
author | Igor Sysoev <igor@sysoev.ru> | 2006-03-10 15:51:52 +0300 |
---|---|---|
committer | Igor Sysoev <igor@sysoev.ru> | 2006-03-10 15:51:52 +0300 |
commit | 13c68741f29943d0ba45f7c9d5a5c4251d5f16f6 (patch) | |
tree | 539580ab05f906419ca310ab8e0d437a1ae7fec8 /src/http/modules | |
parent | 15465ff78e5b53c9fb88dfde0adb8c99f6066892 (diff) |
nginx-0.3.31-RELEASE importrelease-0.3.31
*) Change: now nginx passes the malformed proxied backend responses.
*) Feature: the "listen" directives support the address in the "*:port"
form.
*) Feature: the EVFILER_TIMER support in MacOSX 10.4.
*) Workaround: for MacOSX 64-bit kernel kqueue millisecond timeout
bug.
Thanks to Andrei Nigmatulin.
*) Bugfix: if there were several "listen" directives listening one
various addresses inside one server, then server names like
"*.domain.tld" worked for first address only; the bug had appeared
in 0.3.18.
*) Bugfix: if the HTTPS protocol was used in the "proxy_pass" directive
and the request body was in temporarily file then the request was
not transferred.
*) Bugfix: perl 5.8.8 compatibility.
Diffstat (limited to 'src/http/modules')
-rw-r--r-- | src/http/modules/ngx_http_fastcgi_module.c | 3 | ||||
-rw-r--r-- | src/http/modules/ngx_http_proxy_module.c | 9 | ||||
-rw-r--r-- | src/http/modules/perl/Makefile.PL | 1 | ||||
-rw-r--r-- | src/http/modules/perl/ngx_http_perl_module.c | 2 |
4 files changed, 10 insertions, 5 deletions
diff --git a/src/http/modules/ngx_http_fastcgi_module.c b/src/http/modules/ngx_http_fastcgi_module.c index 978c32542..715b07020 100644 --- a/src/http/modules/ngx_http_fastcgi_module.c +++ b/src/http/modules/ngx_http_fastcgi_module.c @@ -1043,8 +1043,7 @@ ngx_http_fastcgi_process_header(ngx_http_request_t *r) /* there was error while a header line parsing */ ngx_log_error(NGX_LOG_ERR, r->connection->log, 0, - ngx_http_upstream_header_errors[rc - - NGX_HTTP_PARSE_HEADER_ERROR]); + "upstream sent invalid header"); return NGX_HTTP_UPSTREAM_INVALID_HEADER; diff --git a/src/http/modules/ngx_http_proxy_module.c b/src/http/modules/ngx_http_proxy_module.c index e66b48b8b..34e6dd197 100644 --- a/src/http/modules/ngx_http_proxy_module.c +++ b/src/http/modules/ngx_http_proxy_module.c @@ -800,9 +800,11 @@ ngx_http_proxy_process_status_line(ngx_http_request_t *r) ngx_log_error(NGX_LOG_ERR, r->connection->log, 0, "upstream sent no valid HTTP/1.0 header"); +#if 0 if (u->accel) { return NGX_HTTP_UPSTREAM_INVALID_HEADER; } +#endif r->http_version = NGX_HTTP_VERSION_9; p->status = NGX_HTTP_OK; @@ -961,6 +963,10 @@ ngx_http_proxy_parse_status_line(ngx_http_request_t *r, ngx_http_proxy_ctx_t *p) /* HTTP status code */ case sw_status: + if (ch == ' ') { + break; + } + if (ch < '0' || ch > '9') { return NGX_HTTP_PROXY_PARSE_NO_HEADER; } @@ -1111,8 +1117,7 @@ ngx_http_proxy_process_header(ngx_http_request_t *r) /* there was error while a header line parsing */ ngx_log_error(NGX_LOG_ERR, r->connection->log, 0, - ngx_http_upstream_header_errors[rc - - NGX_HTTP_PARSE_HEADER_ERROR]); + "upstream sent invalid header"); return NGX_HTTP_UPSTREAM_INVALID_HEADER; } diff --git a/src/http/modules/perl/Makefile.PL b/src/http/modules/perl/Makefile.PL index 6fa3df744..48f1ebcd2 100644 --- a/src/http/modules/perl/Makefile.PL +++ b/src/http/modules/perl/Makefile.PL @@ -13,6 +13,7 @@ WriteMakefile( AUTHOR => 'Igor Sysoev', CCFLAGS => "$ENV{NGX_PERL_CFLAGS}", + OPTIMIZE => '-O', INC => "-I ../../../../../src/core " . "-I ../../../../../src/event " . diff --git a/src/http/modules/perl/ngx_http_perl_module.c b/src/http/modules/perl/ngx_http_perl_module.c index 069c21646..0a982e6e4 100644 --- a/src/http/modules/perl/ngx_http_perl_module.c +++ b/src/http/modules/perl/ngx_http_perl_module.c @@ -632,7 +632,7 @@ ngx_http_perl_call_handler(pTHX_ ngx_http_request_t *r, SV *sub, "call_sv: %d", status); } else { - line = POPpx; + line = SvPVx(POPs, n_a); rv->len = n_a; rv->data = ngx_palloc(r->pool, n_a); |