commit b0984f4e97cfd7a3274b1510c40e5d2bdf10b531 Author: Jacob Appelbaum jacob@appelbaum.net Date: Wed Aug 24 16:42:14 2011 +0200
use the system torrc by default here --- packages/torouter-web/src/tui/utils/parsing.py | 6 +++++- 1 files changed, 5 insertions(+), 1 deletions(-)
diff --git a/packages/torouter-web/src/tui/utils/parsing.py b/packages/torouter-web/src/tui/utils/parsing.py index 4d52c87..690d15d 100644 --- a/packages/torouter-web/src/tui/utils/parsing.py +++ b/packages/torouter-web/src/tui/utils/parsing.py @@ -6,7 +6,11 @@ import os, re class interfaces: def __init__(self,filename): self.filename = filename - self.fp = open(filename, "r") + try: + self.fp = open(filename, "r") + except: + # this will happen on our first run or at reboot + self.fp = open("/etc/tor/torrc", "r") self.wifi = {} self.eth1 = {} self.eth0 = {}
tor-commits@lists.torproject.org