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

[tor-commits] [oonib/master] Fix bug in exception handling code.



commit b77c577d283b8797f17369ff34edf478fc4a13fb
Author: Arturo Filastò <art@xxxxxxxxx>
Date:   Thu Dec 26 22:56:06 2013 +0100

    Fix bug in exception handling code.
---
 oonib/report/handlers.py |    8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/oonib/report/handlers.py b/oonib/report/handlers.py
index fd008dd..0c727ef 100644
--- a/oonib/report/handlers.py
+++ b/oonib/report/handlers.py
@@ -181,10 +181,10 @@ class NewReportHandlerFile(OONIBHandler):
         # XXX here we should validate and sanitize the request
         try:
             report_data = parseNewReportRequest(self.request.body)
-        except InvalidRequestField, e:
-            raise e.InvalidRequestField(e)
-        except MissingField, e:
-            raise e.MissingRequestField(e)
+        except InvalidRequestField, exc:
+            raise e.InvalidRequestField(exc)
+        except MissingField, exc:
+            raise e.MissingRequestField(exc)
 
         log.debug("Parsed this data %s" % report_data)
 



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