Mercurial > hg > nginx
comparison src/http/ngx_http_special_response.c @ 158:d377ee423603
nginx-0.0.1-2003-10-24-10:53:41 import
author | Igor Sysoev <igor@sysoev.ru> |
---|---|
date | Fri, 24 Oct 2003 06:53:41 +0000 |
parents | 46eb23d9471d |
children | 88abd07d9f62 |
comparison
equal
deleted
inserted
replaced
157:70b36c805682 | 158:d377ee423603 |
---|---|
150 }; | 150 }; |
151 | 151 |
152 | 152 |
153 int ngx_http_special_response_handler(ngx_http_request_t *r, int error) | 153 int ngx_http_special_response_handler(ngx_http_request_t *r, int error) |
154 { | 154 { |
155 int err, rc; | 155 int err, rc; |
156 ngx_hunk_t *h; | 156 ngx_hunk_t *h; |
157 ngx_chain_t *out, **ll, *cl; | 157 ngx_chain_t *out, **ll, *cl; |
158 ngx_http_core_loc_conf_t *clcf; | |
158 | 159 |
159 r->headers_out.status = error; | 160 r->headers_out.status = error; |
160 | 161 |
161 if (error < NGX_HTTP_BAD_REQUEST) { | 162 if (error < NGX_HTTP_BAD_REQUEST) { |
162 /* 3XX */ | 163 /* 3XX */ |
236 h->last = error_tail + sizeof(error_tail) - 1; | 237 h->last = error_tail + sizeof(error_tail) - 1; |
237 | 238 |
238 ngx_alloc_link_and_set_hunk(cl, h, r->pool, NGX_ERROR); | 239 ngx_alloc_link_and_set_hunk(cl, h, r->pool, NGX_ERROR); |
239 ngx_chain_add_link(out, ll, cl); | 240 ngx_chain_add_link(out, ll, cl); |
240 | 241 |
241 if (/* STUB: "msie_padding on/off" */ 1 | 242 clcf = ngx_http_get_module_loc_conf(r, ngx_http_core_module); |
243 | |
244 if (clcf->msie_padding | |
242 && r->http_version >= NGX_HTTP_VERSION_10 | 245 && r->http_version >= NGX_HTTP_VERSION_10 |
243 && error >= NGX_HTTP_BAD_REQUEST | 246 && error >= NGX_HTTP_BAD_REQUEST |
244 && error != NGX_HTTP_REQUEST_URI_TOO_LARGE | 247 && error != NGX_HTTP_REQUEST_URI_TOO_LARGE |
245 ) | 248 ) |
246 { | 249 { |