Correctly handle range requests when using sendfile and the APR/native HTTP connector.
authormarkt <markt@13f79535-47bb-0310-9956-ffa450edef68>
Sun, 5 Jun 2011 10:21:25 +0000 (10:21 +0000)
committermarkt <markt@13f79535-47bb-0310-9956-ffa450edef68>
Sun, 5 Jun 2011 10:21:25 +0000 (10:21 +0000)
git-svn-id: https://svn.apache.org/repos/asf/tomcat/trunk@1132367 13f79535-47bb-0310-9956-ffa450edef68

java/org/apache/coyote/http11/Http11AprProcessor.java
webapps/docs/changelog.xml

index 37fa1b2..d1bc3c7 100644 (file)
@@ -831,7 +831,7 @@ public class Http11AprProcessor extends AbstractHttp11Processor {
             sendfileData.start = ((Long) request.getAttribute(
                     "org.apache.tomcat.sendfile.start")).longValue();
             sendfileData.end = ((Long) request.getAttribute(
-                    "org.apache.tomcat.sendfile.end")).longValue();
+                    "org.apache.tomcat.sendfile.end")).longValue() - sendfileData.pos;
             return true;
         }
         return false;
index 7b2f9e6..35ad9e7 100644 (file)
   General, Catalina, Coyote, Jasper, Cluster, Web applications, Extras, Tribes,
   Other
 -->
+<section name="Tomcat 7.0.16 (markt)">
+  <subsection name="Coyote">
+    <changelog>
+      <fix>
+        Correctly handle range requests when using sendfile and the APR/native
+        HTTP connector. (markt)
+      </fix>
+    </changelog>
+  </subsection>
+</section>
 <section name="Tomcat 7.0.15 (markt)">
   <subsection name="Catalina">
     <changelog>