[or-cvs] r18583: {torctl} Woops, this returns a list.. (torctl/trunk/python/TorCtl)
mikeperry at seul.org
mikeperry at seul.org
Tue Feb 17 02:45:34 UTC 2009
Author: mikeperry
Date: 2009-02-16 21:45:33 -0500 (Mon, 16 Feb 2009)
New Revision: 18583
Modified:
torctl/trunk/python/TorCtl/TorCtl.py
Log:
Woops, this returns a list..
Modified: torctl/trunk/python/TorCtl/TorCtl.py
===================================================================
--- torctl/trunk/python/TorCtl/TorCtl.py 2009-02-16 23:02:49 UTC (rev 18582)
+++ torctl/trunk/python/TorCtl/TorCtl.py 2009-02-17 02:45:33 UTC (rev 18583)
@@ -1135,6 +1135,12 @@
for i in d.idlist:
ns = self.c.get_network_status("id/"+i)
r = self.c.read_routers(ns)
+ if not r:
+ plog("WARN", "No router desc for "+i+" after NEWDESC")
+ continue
+ elif if len(r) != 1:
+ plog("WARN", "Multiple descs for "+i+" after NEWDESC")
+ r = r[0]
if r and r.idhex in self.consensus:
if ns.orhash != self.consensus[r.idhex].orhash:
plog("WARN", "Getinfo and consensus disagree for "+r.idhex)
More information about the tor-commits
mailing list