Mercurial > hg > nginx-quic
comparison src/http/ngx_http_header_filter.c @ 438:e56ab5ac8c65
nginx-0.0.12-2004-09-24-20:12:19 import
author | Igor Sysoev <igor@sysoev.ru> |
---|---|
date | Fri, 24 Sep 2004 16:12:19 +0000 |
parents | 11362a3e3911 |
children | 4fe393d82f44 |
comparison
equal
deleted
inserted
replaced
437:470270fa84d2 | 438:e56ab5ac8c65 |
---|---|
244 * Opera keeps the connection alive very long. | 244 * Opera keeps the connection alive very long. |
245 * Mozilla keeps the connection alive for N plus about 1-10 seconds. | 245 * Mozilla keeps the connection alive for N plus about 1-10 seconds. |
246 * Konqueror keeps the connection alive for about N seconds. | 246 * Konqueror keeps the connection alive for about N seconds. |
247 */ | 247 */ |
248 | 248 |
249 if (clcf->keepalive_header | 249 if (clcf->keepalive_header) { |
250 && (r->headers_in.gecko || r->headers_in.konqueror)) | |
251 { | |
252 len += sizeof("Keep-Alive: timeout=") - 1 + TIME_T_LEN + 2; | 250 len += sizeof("Keep-Alive: timeout=") - 1 + TIME_T_LEN + 2; |
253 } | 251 } |
254 | 252 |
255 } else { | 253 } else { |
256 len += sizeof("Connection: closed" CRLF) - 1; | 254 len += sizeof("Connection: closed" CRLF) - 1; |
378 | 376 |
379 if (r->keepalive) { | 377 if (r->keepalive) { |
380 b->last = ngx_cpymem(b->last, "Connection: keep-alive" CRLF, | 378 b->last = ngx_cpymem(b->last, "Connection: keep-alive" CRLF, |
381 sizeof("Connection: keep-alive" CRLF) - 1); | 379 sizeof("Connection: keep-alive" CRLF) - 1); |
382 | 380 |
383 if (clcf->keepalive_header | 381 if (clcf->keepalive_header) { |
384 && (r->headers_in.gecko || r->headers_in.konqueror)) | |
385 { | |
386 b->last += ngx_snprintf((char *) b->last, | 382 b->last += ngx_snprintf((char *) b->last, |
387 sizeof("Keep-Alive: timeout=") + TIME_T_LEN + 2, | 383 sizeof("Keep-Alive: timeout=") + TIME_T_LEN + 2, |
388 "Keep-Alive: timeout=" TIME_T_FMT CRLF, | 384 "Keep-Alive: timeout=" TIME_T_FMT CRLF, |
389 clcf->keepalive_header); | 385 clcf->keepalive_header); |
390 } | 386 } |