gnunet-svn
[Top][All Lists]
Advanced

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

[GNUnet-SVN] r2451 - GNUnet/src/util


From: grothoff
Subject: [GNUnet-SVN] r2451 - GNUnet/src/util
Date: Tue, 17 Jan 2006 19:20:00 -0800 (PST)

Author: grothoff
Date: 2006-01-17 19:19:59 -0800 (Tue, 17 Jan 2006)
New Revision: 2451

Modified:
   GNUnet/src/util/statuscalls.c
Log:
mantis 1015

Modified: GNUnet/src/util/statuscalls.c
===================================================================
--- GNUnet/src/util/statuscalls.c       2006-01-15 18:11:38 UTC (rev 2450)
+++ GNUnet/src/util/statuscalls.c       2006-01-18 03:19:59 UTC (rev 2451)
@@ -683,21 +683,21 @@
     MUTEX_UNLOCK(&statusMutex);
     return -1;
   }
-  if (maxNetDownBPS == 0) {
+  if (maxNetUpBPS == 0) {
     MUTEX_UNLOCK(&statusMutex);
     return -1;
   }
   if (now - lastCall < cronSECONDS) {
     /* increase last load proportional to difference in
        data transmitted and in relation to the limit */
-    ret = lastValue + 100 * (currentLoadSum - lastSum) / maxNetDownBPS;
+    ret = lastValue + 100 * (currentLoadSum - lastSum) / maxNetUpBPS;
     MUTEX_UNLOCK(&statusMutex);
     return ret;
   }
   currentLoadSum -= lastSum;
   lastSum += currentLoadSum;
   currentLoadSum += overload;
-  maxExpect = ( (now - lastCall) * maxNetDownBPS ) / cronSECONDS;
+  maxExpect = ( (now - lastCall) * maxNetUpBPS ) / cronSECONDS;
   lastCall = now;
   if (currentLoadSum < maxExpect)
     overload = 0;





reply via email to

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