mldonkey-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Mldonkey-commits] mldonkey distrib/ChangeLog src/daemon/common/co...


From: mldonkey-commits
Subject: [Mldonkey-commits] mldonkey distrib/ChangeLog src/daemon/common/co...
Date: Thu, 01 Jun 2006 01:40:28 +0000

CVSROOT:        /sources/mldonkey
Module name:    mldonkey
Branch:         
Changes by:     spiralvoice <address@hidden>    06/06/01 01:40:28

Modified files:
        distrib        : ChangeLog 
        src/daemon/common: commonClient.ml commonComplexOptions.ml 
                           commonInteractive.ml 
        src/daemon/driver: driverCommands.ml 
        src/networks/donkey: donkeyClient.ml donkeyInteractive.ml 
        src/networks/gnutella: gnutellaInteractive.ml 

Log message:
        patch #5152

CVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/mldonkey/mldonkey/distrib/ChangeLog.diff?tr1=1.868&tr2=1.869&r1=text&r2=text
http://cvs.savannah.gnu.org/viewcvs/mldonkey/mldonkey/src/daemon/common/commonClient.ml.diff?tr1=1.26&tr2=1.27&r1=text&r2=text
http://cvs.savannah.gnu.org/viewcvs/mldonkey/mldonkey/src/daemon/common/commonComplexOptions.ml.diff?tr1=1.54&tr2=1.55&r1=text&r2=text
http://cvs.savannah.gnu.org/viewcvs/mldonkey/mldonkey/src/daemon/common/commonInteractive.ml.diff?tr1=1.69&tr2=1.70&r1=text&r2=text
http://cvs.savannah.gnu.org/viewcvs/mldonkey/mldonkey/src/daemon/driver/driverCommands.ml.diff?tr1=1.149&tr2=1.150&r1=text&r2=text
http://cvs.savannah.gnu.org/viewcvs/mldonkey/mldonkey/src/networks/donkey/donkeyClient.ml.diff?tr1=1.92&tr2=1.93&r1=text&r2=text
http://cvs.savannah.gnu.org/viewcvs/mldonkey/mldonkey/src/networks/donkey/donkeyInteractive.ml.diff?tr1=1.107&tr2=1.108&r1=text&r2=text
http://cvs.savannah.gnu.org/viewcvs/mldonkey/mldonkey/src/networks/gnutella/gnutellaInteractive.ml.diff?tr1=1.56&tr2=1.57&r1=text&r2=text

Patches:
Index: mldonkey/distrib/ChangeLog
diff -u mldonkey/distrib/ChangeLog:1.868 mldonkey/distrib/ChangeLog:1.869
--- mldonkey/distrib/ChangeLog:1.868    Wed May 31 22:26:05 2006
+++ mldonkey/distrib/ChangeLog  Thu Jun  1 01:40:28 2006
@@ -15,6 +15,7 @@
 =========
 
 2006/06/01
+5152: Do not connect friends from disabled networks
 5151: Options: New stringvalue functions needed for multiuser support
 5150: Log: Fix log when server list is empty in check_blocked_servers
 
Index: mldonkey/src/daemon/common/commonClient.ml
diff -u mldonkey/src/daemon/common/commonClient.ml:1.26 
mldonkey/src/daemon/common/commonClient.ml:1.27
--- mldonkey/src/daemon/common/commonClient.ml:1.26     Mon Jan 16 16:05:14 2006
+++ mldonkey/src/daemon/common/commonClient.ml  Thu Jun  1 01:40:28 2006
@@ -124,10 +124,6 @@
   let client = as_client_impl client in
   client.impl_client_ops.op_client_to_option client.impl_client_val
 
-let client_network (client : client) =
-  let client = as_client_impl client in
-  client.impl_client_ops.op_client_network
-
 let client_info (client : client) =
   let client = as_client_impl client in
   client.impl_client_ops.op_client_info client.impl_client_val
@@ -173,6 +169,8 @@
   client.impl_client_ops.op_client_clear_files client.impl_client_val
 
 let client_browse client immediate =
+  if CommonNetwork.network_is_enabled
+     ((as_client_impl client).impl_client_ops.op_client_network) then
   let client = as_client_impl client in
   client.impl_client_ops.op_client_browse client.impl_client_val immediate
 
Index: mldonkey/src/daemon/common/commonComplexOptions.ml
diff -u mldonkey/src/daemon/common/commonComplexOptions.ml:1.54 
mldonkey/src/daemon/common/commonComplexOptions.ml:1.55
--- mldonkey/src/daemon/common/commonComplexOptions.ml:1.54     Fri May 19 
23:43:53 2006
+++ mldonkey/src/daemon/common/commonComplexOptions.ml  Thu Jun  1 01:40:28 2006
@@ -1155,3 +1155,9 @@
   Unix32.max_cache_size := total_files - 20;
   calc_real_max_indirect_connections ()
 )
+
+let _ =
+  Heap.add_memstat "CommonComplexOptions" (fun level buf ->
+      Printf.bprintf buf "  friends: %d\n" (List.length !!friends);
+      Printf.bprintf buf "  contacts: %d\n" (List.length !contacts);
+  )
Index: mldonkey/src/daemon/common/commonInteractive.ml
diff -u mldonkey/src/daemon/common/commonInteractive.ml:1.69 
mldonkey/src/daemon/common/commonInteractive.ml:1.70
--- mldonkey/src/daemon/common/commonInteractive.ml:1.69        Fri May 19 
23:43:54 2006
+++ mldonkey/src/daemon/common/commonInteractive.ml     Thu Jun  1 01:40:28 2006
@@ -426,7 +426,8 @@
       client_must_update c;
       friends =:= c :: !!friends;
       contacts := List2.removeq c !contacts;
-      impl.impl_client_ops.op_client_browse impl.impl_client_val true
+      if network_is_enabled ((as_client_impl 
c).impl_client_ops.op_client_network) then
+        impl.impl_client_ops.op_client_browse impl.impl_client_val true
     end
 
 (* Maybe we should not add the client to the contact list and completely remove
@@ -456,7 +457,8 @@
       set_contact c;
       client_must_update c;
       contacts := c :: !contacts;
-      impl.impl_client_ops.op_client_browse impl.impl_client_val true
+      if network_is_enabled ((as_client_impl 
c).impl_client_ops.op_client_network) then
+        impl.impl_client_ops.op_client_browse impl.impl_client_val true
     end
 
 let contact_remove c =
Index: mldonkey/src/daemon/driver/driverCommands.ml
diff -u mldonkey/src/daemon/driver/driverCommands.ml:1.149 
mldonkey/src/daemon/driver/driverCommands.ml:1.150
--- mldonkey/src/daemon/driver/driverCommands.ml:1.149  Tue May 30 10:55:21 2006
+++ mldonkey/src/daemon/driver/driverCommands.ml        Thu Jun  1 01:40:28 2006
@@ -1053,7 +1053,6 @@
                       rs, r, 1
                   ) rs in
                 o.conn_user.ui_last_results <- [];
-                Printf.bprintf buf "Reinitialising download selectors\n";
                 DriverInteractive.print_results 0 buf o rs;
 
                 ()
Index: mldonkey/src/networks/donkey/donkeyClient.ml
diff -u mldonkey/src/networks/donkey/donkeyClient.ml:1.92 
mldonkey/src/networks/donkey/donkeyClient.ml:1.93
--- mldonkey/src/networks/donkey/donkeyClient.ml:1.92   Wed May 31 20:02:14 2006
+++ mldonkey/src/networks/donkey/donkeyClient.ml        Thu Jun  1 01:40:28 2006
@@ -790,10 +790,6 @@
 let query_view_files c =
   if client_browsed_tag land client_type c <> 0 then begin
       if last_time () > c.client_next_view_files then begin
-(*
-lprintf "****************************************\n";
-lprintf "       ASK VIEW FILES         \n";
-  *)
           c.client_next_view_files <- last_time () + 3600 * 6;
           client_send c (
             let module M = DonkeyProtoClient in
Index: mldonkey/src/networks/donkey/donkeyInteractive.ml
diff -u mldonkey/src/networks/donkey/donkeyInteractive.ml:1.107 
mldonkey/src/networks/donkey/donkeyInteractive.ml:1.108
--- mldonkey/src/networks/donkey/donkeyInteractive.ml:1.107     Thu May 25 
19:47:25 2006
+++ mldonkey/src/networks/donkey/donkeyInteractive.ml   Thu Jun  1 01:40:28 2006
@@ -1541,23 +1541,16 @@
       | Some files ->
           List2.tail_map (fun r -> "", r) files);
   client_ops.op_client_browse <- (fun c immediate ->
-      lprintf_nl "*************** should browse  ***********";
+      if !verbose then lprintf_nl "connecting friend %s" 
(full_client_identifier c);
       match c.client_source.DonkeySources.source_sock with
-      | Connection sock    ->
-(*
-      lprintf "****************************************";
-      lprint_newline ();
-      lprintf "       ASK VIEW FILES         ";
-lprint_newline ();
-  *)
+      | Connection sock ->
+         if !verbose then lprintf_nl "retrieving filelist from friend %s" 
(full_client_identifier c);
           client_send c (
             let module M = DonkeyProtoClient in
             let module C = M.ViewFiles in
             M.ViewFilesReq C.t);
       | NoConnection ->
-          lprintf_nl "****************************************";
-          lprintf_nl "       TRYING TO CONTACT FRIEND";
-
+         if !verbose then lprintf_nl "re-connecting friend %s" 
(full_client_identifier c);
           reconnect_client c
       | _ -> ()
   );
Index: mldonkey/src/networks/gnutella/gnutellaInteractive.ml
diff -u mldonkey/src/networks/gnutella/gnutellaInteractive.ml:1.56 
mldonkey/src/networks/gnutella/gnutellaInteractive.ml:1.57
--- mldonkey/src/networks/gnutella/gnutellaInteractive.ml:1.56  Wed May 31 
20:02:57 2006
+++ mldonkey/src/networks/gnutella/gnutellaInteractive.ml       Thu Jun  1 
01:40:28 2006
@@ -401,10 +401,6 @@
           else "", false
   )
   
-let browse_client c = 
-  lprintf "Gnutella: browse client not implemented\n";
-  ()
-  
 let _ =
   client_ops.op_client_info <- (fun c ->
       { (impl_client_info c.client_client) with
@@ -419,8 +415,7 @@
 
       }
   );
-  client_ops.op_client_browse <- (fun c immediate ->
-      browse_client c
+  client_ops.op_client_browse <- (fun _ _ -> lprintf_nl "Gnutella: browse 
client not implemented";
   );
 
     client_ops.op_client_bprint <- (fun c buf ->




reply via email to

[Prev in Thread] Current Thread [Next in Thread]