67 |
let referer = d.download_referer in |
let referer = d.download_referer in |
68 |
|
|
69 |
let (x,y) = range in |
let (x,y) = range in |
70 |
let range = Printf.sprintf "%Ld-%Ld" x (y -- (Int64.one)) in |
let range = Printf.sprintf "%Ld-%Ld" x (Int64.pred y) in |
71 |
|
|
72 |
let buf = Buffer.create 100 in |
let buf = Buffer.create 100 in |
73 |
|
|
208 |
String.sub range (dash_pos+1) (slash_pos - dash_pos - 1)) |
String.sub range (dash_pos+1) (slash_pos - dash_pos - 1)) |
209 |
in |
in |
210 |
if slash_pos = star_pos - 1 then |
if slash_pos = star_pos - 1 then |
211 |
x,y ++ Int64.one (* "bytes x-y/*" *) |
x, Int64.succ y (* "bytes x-y/*" *) |
212 |
else |
else |
213 |
let z = Int64.of_string ( |
let z = Int64.of_string ( |
214 |
String.sub range (slash_pos+1) (len - slash_pos -1) ) |
String.sub range (slash_pos+1) (len - slash_pos -1) ) |
215 |
in |
in |
216 |
if y = z then x -- Int64.one, size else |
if y = z then Int64.pred x, size else |
217 |
x,y ++ Int64.one |
x, Int64.succ y |
218 |
with |
with |
219 |
| e -> |
| e -> |
220 |
lprintf_nl () "Exception %s for range [%s]" |
lprintf_nl () "Exception %s for range [%s]" |