diff options
author | Igor Sysoev <igor@sysoev.ru> | 2003-12-08 20:48:12 +0000 |
---|---|---|
committer | Igor Sysoev <igor@sysoev.ru> | 2003-12-08 20:48:12 +0000 |
commit | 5f80078c675bc344d12a6a64d97ecafb64de224b (patch) | |
tree | e4ff5330121ef71ffe558ccaa9210218802ff537 /src/http/modules/proxy/ngx_http_proxy_header.c | |
parent | 62260f2a158e27e5f6b1689e10dc25ea3c617473 (diff) | |
download | nginx-5f80078c675bc344d12a6a64d97ecafb64de224b.tar.gz nginx-5f80078c675bc344d12a6a64d97ecafb64de224b.zip |
nginx-0.0.1-2003-12-08-23:48:12 import
Diffstat (limited to 'src/http/modules/proxy/ngx_http_proxy_header.c')
-rw-r--r-- | src/http/modules/proxy/ngx_http_proxy_header.c | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/src/http/modules/proxy/ngx_http_proxy_header.c b/src/http/modules/proxy/ngx_http_proxy_header.c index 76d33211c..0c44a5248 100644 --- a/src/http/modules/proxy/ngx_http_proxy_header.c +++ b/src/http/modules/proxy/ngx_http_proxy_header.c @@ -23,7 +23,7 @@ int ngx_http_proxy_copy_header(ngx_http_proxy_ctx_t *p, if (&h[i] == headers_in->connection) { continue; } - + if (p->accel) { if (&h[i] == headers_in->date || &h[i] == headers_in->accept_ranges) { @@ -34,12 +34,12 @@ int ngx_http_proxy_copy_header(ngx_http_proxy_ctx_t *p, && !p->lcf->pass_x_accel_expires) { continue; - } - + } + if (&h[i] == headers_in->server && !p->lcf->pass_server) { continue; - } - + } + if (&h[i] == headers_in->location) { if (ngx_http_proxy_rewrite_location_header(p, &h[i]) == NGX_ERROR) @@ -48,9 +48,9 @@ int ngx_http_proxy_copy_header(ngx_http_proxy_ctx_t *p, } continue; - } + } } - + if (&h[i] == headers_in->content_type) { r->headers_out.content_type = &h[i]; r->headers_out.content_type->key.len = 0; @@ -61,9 +61,9 @@ int ngx_http_proxy_copy_header(ngx_http_proxy_ctx_t *p, { return NGX_ERROR; } - + *ho = h[i]; - + /* * ngx_http_header_filter() does not handle specially * the following headers if they are set: @@ -122,7 +122,7 @@ static int ngx_http_proxy_rewrite_location_header(ngx_http_proxy_ctx_t *p, r->headers_out.location->value.len = uc->location->len + (loc->value.len - uc->url.len) + 1; r->headers_out.location->value.data = - ngx_palloc(r->pool, r->headers_out.location->value.len); + ngx_palloc(r->pool, r->headers_out.location->value.len); if (r->headers_out.location->value.data == NULL) { return NGX_ERROR; |