Index: server/protocol.c
===================================================================
RCS file: /home/cvs/httpd-2.0/server/protocol.c,v
retrieving revision 1.139
diff -u -r1.139 protocol.c
--- server/protocol.c	16 Nov 2003 02:09:14 -0000	1.139
+++ server/protocol.c	18 Dec 2003 23:46:27 -0000
@@ -190,8 +190,13 @@
 AP_DECLARE(void) ap_set_content_length(request_rec *r, apr_off_t clength)
 {
     r->clength = clength;
-    apr_table_setn(r->headers_out, "Content-Length",
-                   apr_off_t_toa(r->pool, clength));
+#if APR_HAS_LARGE_FILES
+    /* Dont't set the content-length if the length is greater than 0x80000000-1.
+       Browsers don't seem to be able to handle it.*/ 
+    if (clength <= 0x7FFFFFFF)
+#endif
+        apr_table_setn(r->headers_out, "Content-Length",
+                       apr_off_t_toa(r->pool, clength));
 }
 
 /*
