If a higher-level filter handles the the byterange aspects of a

request, then the byterange filter should not try to redo the
work.  The most common case of this happening, is a byterange
request going through the proxy, and the origin server handles
the byterange request.  The proxy should ignore it.

Submitted by:	Graham Leggett <minfrin@sharp.fm>


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@88873 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Ryan Bloom
2001-04-16 21:16:53 +00:00
parent 29b5864cbf
commit a7bc1f3efa
2 changed files with 19 additions and 0 deletions

View File

@ -2347,6 +2347,18 @@ static int ap_set_byterange(request_rec *r)
if (r->assbackwards)
return 0;
/* is content already a single range? */
if (apr_table_get(r->headers_out, "Content-Range")) {
return 0;
}
/* is content already a multiple range? */
if ((ct = apr_table_get(r->headers_out, "Content-Type")) &&
(!strncasecmp(ct, "multipart/byteranges", 20) ||
!strncasecmp(ct, "multipart/x-byteranges", 22))) {
return 0;
}
/* Check for Range request-header (HTTP/1.1) or Request-Range for
* backwards-compatibility with second-draft Luotonen/Franks
* byte-ranges (e.g. Netscape Navigator 2-3).