[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]
[tor-commits] [arm/master] fix: avoiding catch-all during controller init
commit 7e8427563602a709afdc8a34585d9cbd905d8c87
Author: Damian Johnson <atagar@xxxxxxxxxxxxxx>
Date: Tue Jul 19 09:18:23 2011 -0700
fix: avoiding catch-all during controller init
Misplaced finally clause is obscuring any exceptions that are raised during
arm's initialization. Only doing daemon shutdown for expected issues so
unexpected issues are propagated.
---
src/cli/controller.py | 5 +++--
1 files changed, 3 insertions(+), 2 deletions(-)
diff --git a/src/cli/controller.py b/src/cli/controller.py
index e8b28cc..1554949 100644
--- a/src/cli/controller.py
+++ b/src/cli/controller.py
@@ -661,9 +661,10 @@ def startTorMonitor(startTime):
try:
curses.wrapper(drawTorMonitor, startTime)
+ shutdownDaemons()
except KeyboardInterrupt:
- pass # skip printing stack trace in case of keyboard interrupt
- finally: shutdownDaemons()
+ # skip printing stack trace in case of keyboard interrupt
+ shutdownDaemons()
def drawTorMonitor(stdscr, startTime):
"""
_______________________________________________
tor-commits mailing list
tor-commits@xxxxxxxxxxxxxxxxxxxx
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-commits