Mercurial > hg > nginx-quic
comparison src/http/ngx_http_variables.c @ 4732:613390a974df stable-1.2
Merge of r4698: X-Forwarded-For conditionals.
Fixed compile-time conditionals used to detect if X-Forwarded-For support
is needed.
Note: compatibility shims were added during merge to avoid possible
breakage of 3rd party modules. At least cache purge module was broken
by the original commit, as it used to rely on NGX_HTTP_PROXY define.
author | Maxim Dounin <mdounin@mdounin.ru> |
---|---|
date | Mon, 02 Jul 2012 17:41:52 +0000 |
parents | dad38cdaf496 |
children | 5cad4cb1f484 |
comparison
equal
deleted
inserted
replaced
4731:9efa21520c84 | 4732:613390a974df |
---|---|
132 #if (NGX_HTTP_GZIP) | 132 #if (NGX_HTTP_GZIP) |
133 { ngx_string("http_via"), NULL, ngx_http_variable_header, | 133 { ngx_string("http_via"), NULL, ngx_http_variable_header, |
134 offsetof(ngx_http_request_t, headers_in.via), 0, 0 }, | 134 offsetof(ngx_http_request_t, headers_in.via), 0, 0 }, |
135 #endif | 135 #endif |
136 | 136 |
137 #if (NGX_HTTP_PROXY || NGX_HTTP_REALIP) | 137 #if (NGX_HTTP_X_FORWARDED_FOR) |
138 { ngx_string("http_x_forwarded_for"), NULL, ngx_http_variable_header, | 138 { ngx_string("http_x_forwarded_for"), NULL, ngx_http_variable_header, |
139 offsetof(ngx_http_request_t, headers_in.x_forwarded_for), 0, 0 }, | 139 offsetof(ngx_http_request_t, headers_in.x_forwarded_for), 0, 0 }, |
140 #endif | 140 #endif |
141 | 141 |
142 { ngx_string("http_cookie"), NULL, ngx_http_variable_headers, | 142 { ngx_string("http_cookie"), NULL, ngx_http_variable_headers, |