[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

[tor-commits] [flashproxy/master] Shorter num_relays.



commit 704fa5e1cf3669836c9f2b642eda086b866a2cad
Author: David Fifield <david@xxxxxxxxxxxxxxx>
Date:   Fri Sep 20 22:57:48 2013 -0700

    Shorter num_relays.
---
 facilitator/facilitator |    6 +-----
 1 file changed, 1 insertion(+), 5 deletions(-)

diff --git a/facilitator/facilitator b/facilitator/facilitator
index 481ccdd..9610993 100755
--- a/facilitator/facilitator
+++ b/facilitator/facilitator
@@ -70,11 +70,7 @@ again. Listen on 127.0.0.1 and port PORT (by default %(port)d).
 }
 
 def num_relays():
-    num_relays = 0
-    for relay_list in RELAYS.values():
-        num_relays += len(relay_list)
-
-    return num_relays
+    return sum(len(x) for x in RELAYS.values())
 
 def parse_transport_chain(spec):
     """Parse a transport chain string and return a tuple of individual



_______________________________________________
tor-commits mailing list
tor-commits@xxxxxxxxxxxxxxxxxxxx
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-commits