Bug #5802 - Incorrect length in http partial content (206) packets.

This commit is contained in:
skodak
2006-06-30 07:21:55 +00:00
parent 609784e0aa
commit bd93091c8a
+2 -2
View File
@@ -561,9 +561,9 @@ function byteserving_send_file($filename, $mimetype, $ranges) {
} else { // multiple ranges requested - not tested much
$totallength = 0;
foreach($ranges as $range) {
$totallength .= strlen($range[0]) + $range[2] - $range[1] + 1;
$totallength += strlen($range[0]) + $range[2] - $range[1] + 1;
}
$totallength .= strlen("\r\n--".BYTESERVING_BOUNDARY."--\r\n");
$totallength += strlen("\r\n--".BYTESERVING_BOUNDARY."--\r\n");
@header('HTTP/1.1 206 Partial content');
@header('Content-Length: '.$totallength);
@header('Content-Type: multipart/byteranges; boundary='.BYTESERVING_BOUNDARY);