“A customer running my download software reported this error and this is what I found
Chrome shows this error: "Error 346 (net::ERR_RESPONSE_HEADERS_MULTIPLE_CONTENT_LENGTH): Unknown error."
Firefox 7 shows this error: "Corrupted Content Error".
IE 8 does the download, but using Fiddler I saw the error "Content-Length mismatch: Response header indicated 625,804 bytes, but server sent 627,238 bytes.
Googling ERR_RESPONSE_HEADERS_MULTIPLE_CONTENT_LENGTH, I found this:
https://www.varnish-cache.org/trac/ticket/801
- which says that the error relates to multiple Content-Length headers (and now Chrome's error message suddenly makes sense)
So I looked at the headers, and sure enough, the Varnish caching software is installed on the server, and there are two (different) Content-Length headers, one from my download application, and another one, presumably generated by Varnish:
HTTP/1.1 200 OK
Date: Fri, 28 Oct 2011 09:45:31 GMT
Content-Type: application/zip
Connection: close
Server: Nginx / Varnish
X-Powered-By: PHP/5.2.17
P3P: CP="NOI ADM DEV PSAi COM NAV OUR OTRo STP IND DEM"
Cache-Control: pre-check=0, post-check=0, max-age=0
Pragma: no-cache
Content-Description: File Transfer
Expires: Thu, 01 Dec 1994 16:00:00 GMT
Content-Length: 625804
Content-Range: bytes 0-625804/625804
Content-Disposition: attachment; filename="blah.zip"
Content-Transfer-Encoding: binary
Content-Length: 670673
My job is done, I told my customer to get his web server provider to fix it - presumably the solution is to upgrade Varnish.
Chrome could do a better job of reporting this. Maybe it could just ignore the second Content-Length header?”
Bookmarks