gnunet-svn
[Top][All Lists]
Advanced

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

[GNUnet-SVN] r29297 - gnunet/src/ats


From: gnunet
Subject: [GNUnet-SVN] r29297 - gnunet/src/ats
Date: Mon, 16 Sep 2013 13:54:42 +0200

Author: wachs
Date: 2013-09-16 13:54:42 +0200 (Mon, 16 Sep 2013)
New Revision: 29297

Modified:
   gnunet/src/ats/gnunet-service-ats_addresses.c
Log:
add disconnect message


Modified: gnunet/src/ats/gnunet-service-ats_addresses.c
===================================================================
--- gnunet/src/ats/gnunet-service-ats_addresses.c       2013-09-16 11:50:59 UTC 
(rev 29296)
+++ gnunet/src/ats/gnunet-service-ats_addresses.c       2013-09-16 11:54:42 UTC 
(rev 29297)
@@ -775,7 +775,7 @@
   uint32_t previous_session;
   int c1;
 
-  GNUNET_log (GNUNET_ERROR_TYPE_INFO,
+  GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
               "Received `%s' for peer `%s'\n",
               "ADDRESS ADD",
               GNUNET_i2s (peer));
@@ -1678,7 +1678,8 @@
   GNUNET_assert (handle != NULL);
   GNUNET_assert (address != NULL);
 
-  GNUNET_log (GNUNET_ERROR_TYPE_INFO, "Bandwidth assignment changed for peer 
%s \n", GNUNET_i2s(&address->peer));
+  GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "Bandwidth assignment changed for peer 
%s \n",
+               GNUNET_i2s(&address->peer));
 
   /* Notify performance clients about changes to address */
   GAS_performance_notify_all_clients (&address->peer,
@@ -1702,8 +1703,21 @@
       return;
   }
 
-  GNUNET_log (GNUNET_ERROR_TYPE_INFO,
-              "Sending bandwidth update for peer `%s'\n",GNUNET_i2s 
(&address->peer));
+  if ((0 == ntohl (address->assigned_bw_in.value__)) &&
+               (0 == ntohl (address->assigned_bw_out.value__)))
+  {
+               GNUNET_log (GNUNET_ERROR_TYPE_INFO,
+                                                               "Telling 
transport to disconnect peer `%s'\n",
+                                                               GNUNET_i2s 
(&address->peer));
+  }
+  else
+  {
+               GNUNET_log (GNUNET_ERROR_TYPE_INFO,
+                                                               "Sending 
bandwidth update for peer `%s': %llu %llu\n",
+                                                               GNUNET_i2s 
(&address->peer),
+                                                               
address->assigned_bw_out,
+                                                               
address->assigned_bw_out);
+  }
 
   /* *Notify scheduling clients about suggestion */
   GAS_scheduling_transmit_address_suggestion (&address->peer,




reply via email to

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