fix $r->header_in() for "User-Agent", "Connection", and "Host"
broken in r2005, r2006, and r2008.
Igor Sysoev
13 years ago
73 | 73 | |
74 | 74 | |
75 | 75 | ngx_http_header_t ngx_http_headers_in[] = { |
76 | { ngx_string("Host"), 0, ngx_http_process_host }, | |
77 | ||
78 | { ngx_string("Connection"), 0, ngx_http_process_connection }, | |
76 | { ngx_string("Host"), offsetof(ngx_http_headers_in_t, host), | |
77 | ngx_http_process_host }, | |
78 | ||
79 | { ngx_string("Connection"), offsetof(ngx_http_headers_in_t, connection), | |
80 | ngx_http_process_connection }, | |
79 | 81 | |
80 | 82 | { ngx_string("If-Modified-Since"), |
81 | 83 | offsetof(ngx_http_headers_in_t, if_modified_since), |
82 | 84 | ngx_http_process_unique_header_line }, |
83 | 85 | |
84 | { ngx_string("User-Agent"), 0, ngx_http_process_user_agent }, | |
86 | { ngx_string("User-Agent"), offsetof(ngx_http_headers_in_t, user_agent), | |
87 | ngx_http_process_user_agent }, | |
85 | 88 | |
86 | 89 | { ngx_string("Referer"), offsetof(ngx_http_headers_in_t, referer), |
87 | 90 | ngx_http_process_header_line }, |