httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Paul Sutton <p...@ukweb.com>
Subject Re: MSIE + byteranges
Date Fri, 14 Feb 1997 13:14:40 GMT
On Thu, 13 Feb 1997, Alexei Kosut wrote:
> P.S. I have yet to hear from anyone who has access to a Windows
> machine who has tested byterange support as I asked someone to... I'm
> taking Adobe's word that IE 3.0 for Windows is misfunctioning. I'd
> perfer someone here did it. (and that way we'd also know if this patch
> worked! Even if Adobe is right, the problem may involve other things
> Apache does as well.)

This patch works on MSIE 3 (on NT but should be the same on other versions
of MSIE 3 for windows) _only if_ the quotes are removed from the boundary
line. 

With the quotes removed, MSIE + Acrobat plug in make two normal requests
(which it then breaks, I presume this is a request from MSIE then a
request from the plug-in). Incidently, these breaks mean you get lots of
"send lost connection to client" in the error_log, which might worry
users. 

Then the plug-in requests a selection of byte ranges (mostly concurrent
ranges) for the first page. It then downloads each page as needed, using
often very long range headers, for example:

Range: bytes=191133-203653, 616586-617768, 203654-204536, 617769-618005,
784666-786761, 786762-787094, 778068-779417, 764596-765880, 763486-764595,
777000-778067, 768514-769813, 767403-768513, 773428-774722, 772318-773427,
755478-756770, 760687-761964, 754368-755477, 759576-760686, 750160-752257,
752258-752536, 697725-705758, 711422-719309, 719310-726129, 705759-711421,
746640-750159, 726130-733580, 739053-745388, 733581-739052, 745389-746639,
774723-776999, 765881-767402, 769814-772317, 787095-798308, 779418-784665,
752537-754367, 618006-648005, 648006-657628, 761965-763485, 756771-759575,
204537-205269

It should probably check for "MSIE 3" rather than just MSIE.  They ought
to be able to fix this before 4 is released. 

+1 for this patch, with boundary quotes removed.

//pcs

> Index: http_protocol.c
> ===================================================================
> RCS file: /export/home/cvs/apache/src/http_protocol.c,v
> retrieving revision 1.100
> diff -c -r1.100 http_protocol.c
> *** http_protocol.c	1997/02/11 17:02:04	1.100
> --- http_protocol.c	1997/02/14 03:03:48
> ***************
> *** 1052,1057 ****
> --- 1052,1064 ----
>       return OK;
>   }
>   
> + static int use_range_x(request_rec *r) {
> +     char *ua;
> +     return (table_get(r->headers_in, "Request-Range") ||
> + 	    ((ua = table_get(r->headers_in, "User-Agent"))
> + 	     && strstr(ua, "MSIE")));
> + }
> + 
>   void send_http_header(request_rec *r)
>   {
>       conn_rec *c = r->connection;
> ***************
> *** 1082,1090 ****
>   
>       if (r->byterange > 1)
>           bvputs(fd, "Content-Type: multipart/",
> ! 	       table_get(r->headers_in, "Request-Range") ?
> ! 	       "x-byteranges" : "byteranges",
> ! 	       "; boundary=\"", r->boundary, "\"\015\012", NULL);
>       else if (r->content_type)
>           bvputs(fd, "Content-Type: ", 
>   		 nuke_mime_parms (r->pool, r->content_type), "\015\012", NULL);
> --- 1089,1096 ----
>   
>       if (r->byterange > 1)
>           bvputs(fd, "Content-Type: multipart/",
> ! 	       use_range_x(r) ? "x-byteranges" : "byteranges",
> ! 	       "; boundary=", r->boundary, "\015\012", NULL);
>       else if (r->content_type)
>           bvputs(fd, "Content-Type: ", 
>   		 nuke_mime_parms (r->pool, r->content_type), "\015\012", NULL);
> 
> 
> -- 
> ________________________________________________________________________
> Alexei Kosut <akosut@nueva.pvt.k12.ca.us>      The Apache HTTP Server
> URL: http://www.nueva.pvt.k12.ca.us/~akosut/   http://www.apache.org/
> 
> 

Paul Sutton, Technical Director, UK Web ---- http://www.ukweb.com/~paul/
Editor, Apache Week .. the latest Apache news http://www.apacheweek.com/


Mime
View raw message