[or-cvs] when listing min-bandwidth servers in the controller, don"t...

arma at seul.org arma at seul.org
Sun Aug 14 08:38:36 UTC 2005


Update of /home2/or/cvsroot/tor/src/or
In directory moria:/home/arma/work/onion/cvs/tor/src/or

Modified Files:
	dirserv.c 
Log Message:
when listing min-bandwidth servers in the controller, don't get
fooled by a low bandwidthrate


Index: dirserv.c
===================================================================
RCS file: /home2/or/cvsroot/tor/src/or/dirserv.c,v
retrieving revision 1.175
retrieving revision 1.176
diff -u -d -r1.175 -r1.176
--- dirserv.c	13 Aug 2005 02:20:00 -0000	1.175
+++ dirserv.c	14 Aug 2005 08:38:34 -0000	1.176
@@ -463,7 +463,9 @@
   for (i = 0; i < smartlist_len(descriptor_list); ++i) {
     ent = smartlist_get(descriptor_list, i);
     r = dirserv_router_fingerprint_is_known(ent);
-    if (ent->bandwidthcapacity >= min_bw && r == 0) {
+    if (ent->bandwidthcapacity >= min_bw &&
+        ent->bandwidthrate >= min_bw &&
+        r == 0) {
       /* then log this one */
       tor_snprintf(buf, sizeof(buf),
                    "%s: BW %d on '%s'.",



More information about the tor-commits mailing list