/[mldonkey]/mldonkey/src/networks/fileTP/fileTPHTTP.ml
ViewVC logotype

Diff of /mldonkey/src/networks/fileTP/fileTPHTTP.ml

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.12 by spiralvoice, Tue Jul 26 23:16:48 2005 UTC revision 1.13 by spiralvoice, Wed Jul 27 22:16:02 2005 UTC
# Line 64  let lprintf_n () = Line 64  let lprintf_n () =
64    
65  let http_send_range_request c range sock d =  let http_send_range_request c range sock d =
66    let url = d.download_url in    let url = d.download_url in
67      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 (y -- (Int64.one)) in
71    
# Line 80  let http_send_range_request c range sock Line 81  let http_send_range_request c range sock
81                      name); *)                      name); *)
82    Printf.bprintf buf "Host: %s\r\n" c.client_hostname;    Printf.bprintf buf "Host: %s\r\n" c.client_hostname;
83    Printf.bprintf buf "User-Agent: %s\r\n" user_agent;    Printf.bprintf buf "User-Agent: %s\r\n" user_agent;
84      Printf.bprintf buf "Referer: %s\r\n" (Url.to_string referer);
85    Printf.bprintf buf "Range: bytes=%s\r\n" range;    Printf.bprintf buf "Range: bytes=%s\r\n" range;
86    Printf.bprintf buf "Connection: Keep-Alive\r\n";    Printf.bprintf buf "Connection: Keep-Alive\r\n";
87    Printf.bprintf buf "\r\n";    Printf.bprintf buf "\r\n";
# Line 178  let rec client_parse_header c gconn sock Line 180  let rec client_parse_header c gconn sock
180        if not (List.memq file !current_files) then begin        if not (List.memq file !current_files) then begin
181      current_files := file :: !current_files;      current_files := file :: !current_files;
182        end;        end;
183        add_download file c u;        add_download file c u r;
184        FileTPClients.get_file_from_source c file;        FileTPClients.get_file_from_source c file;
185    
186       end;       end;

Legend:
Removed from v.1.12  
changed lines
  Added in v.1.13

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26