Roxen.git/
server/
protocols/
http.pike
Branch:
Tag:
Non-build tags
All tags
No tags
2006-12-07
2006-12-07 16:47:20 by Stefan Wallström <stewa@roxen.com>
feb680c7a80bfd3e658fd69f5ec6569e7877a05d (
7
lines) (+
4
/-
3
)
[
Show
|
Annotate
]
Branch:
5.2
Byte ranges fix from 4.5
Rev: server/protocols/http.pike:1.514
2:
// Modified by Francesco Chemolli to add throttling capabilities. // Copyright © 1996 - 2004, Roxen IS.
-
constant cvs_version = "$Id: http.pike,v 1.
513
2006/
11
/
16
12
:
56
:
55
mast
Exp $";
+
constant cvs_version = "$Id: http.pike,v 1.
514
2006/
12
/
07
16:
47
:
20
stewa
Exp $";
// #define REQUEST_DEBUG #define MAGIC_ERROR
1660:
// Entire file requested here. r1 = 0; }
-
ranges += ({ ({
len - (int)range[1..]
, len-1 }) });
+
ranges += ({ ({
r1
, len-1 }) });
} else if(range[-1] == '-') { // Rest of file request r1 = (int)range;
1762:
res[j++] = Roxen.make_http_headers(part_heads); res[j++] = file->data[range[0]..range[1]]; }
-
res[j++] = "\r\n--" BOUND "\r\n";
+
res[j++] = "\r\n--" BOUND "
--
\r\n";
file->len = sizeof(file->data = res * ""); } }