/[mldonkey]/mldonkey/src/daemon/common/commonShared.ml
ViewVC logotype

Diff of /mldonkey/src/daemon/common/commonShared.ml

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

revision 1.20 by spiralvoice, Sun Jul 17 16:12:59 2005 UTC revision 1.21 by spiralvoice, Sun Jul 17 16:36:07 2005 UTC
# Line 168  let shared_codedname s = Line 168  let shared_codedname s =
168        
169  let shared_unshare s =  let shared_unshare s =
170    let impl = as_shared_impl s in    let impl = as_shared_impl s in
171      shared_remove impl;
172    try impl.impl_shared_ops.op_shared_unshare impl.impl_shared_val with _ -> ()    try impl.impl_shared_ops.op_shared_unshare impl.impl_shared_val with _ -> ()
173    
174  let shared_dir = function  let shared_dir = function
# Line 319  let shared_add_directory shared_dir = Line 320  let shared_add_directory shared_dir =
320        
321  let shared_check_files () =  let shared_check_files () =
322    let list = ref [] in    let list = ref [] in
323      (* check shared files, store removed files in !list *)
324    H.iter (fun s ->    H.iter (fun s ->
325        let name = shared_fullname s in        let name = shared_fullname s in
326        if not (Unix32.file_exists name) then list := s :: !list        if not (Unix32.file_exists name) then list := s :: !list
327    ) shareds_by_num;    ) shareds_by_num;
328      (* unshare removed files *)
329    List.iter (fun s -> shared_unshare s) !list;    List.iter (fun s -> shared_unshare s) !list;
330    files_scanned_size := zero;    files_scanned_size := zero;
331    files_scanned := 0;    files_scanned := 0;
332    List.iter (fun s -> shared_add_directory s)    List.iter (fun s -> shared_add_directory s)
333    !!  CommonComplexOptions.shared_directories;    !!CommonComplexOptions.shared_directories;
334    shared_calculate_total_bytes ()    shared_calculate_total_bytes ()
335        
336  let impl_shared_info impl =  let impl_shared_info impl =

Legend:
Removed from v.1.20  
changed lines
  Added in v.1.21

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