summaryrefslogtreecommitdiffstats
path: root/Lib/logging
diff options
context:
space:
mode:
authorVinay Sajip <vinay_sajip@yahoo.co.uk>2005-10-31 14:27:01 (GMT)
committerVinay Sajip <vinay_sajip@yahoo.co.uk>2005-10-31 14:27:01 (GMT)
commit245a5ab31bbaa48776736bdd101b0df7164125c9 (patch)
tree1e719c7814b19e44a92939b2d5f3f8aa5bf8fd8e /Lib/logging
parent85c1909a78c97745cd41a56be7bce372b7d60d64 (diff)
downloadcpython-245a5ab31bbaa48776736bdd101b0df7164125c9.zip
cpython-245a5ab31bbaa48776736bdd101b0df7164125c9.tar.gz
cpython-245a5ab31bbaa48776736bdd101b0df7164125c9.tar.bz2
Exception handling now raises KeyboardInterrupt and SystemExit rather than passing to handleError
Diffstat (limited to 'Lib/logging')
-rw-r--r--Lib/logging/handlers.py6
1 files changed, 6 insertions, 0 deletions
diff --git a/Lib/logging/handlers.py b/Lib/logging/handlers.py
index e0ab788..0ffbc47 100644
--- a/Lib/logging/handlers.py
+++ b/Lib/logging/handlers.py
@@ -725,6 +725,8 @@ class SMTPHandler(logging.Handler):
formatdate(), msg)
smtp.sendmail(self.fromaddr, self.toaddrs, msg)
smtp.quit()
+ except (KeyboardInterrupt, SystemExit):
+ raise
except:
self.handleError(record)
@@ -810,6 +812,8 @@ class NTEventLogHandler(logging.Handler):
type = self.getEventType(record)
msg = self.format(record)
self._welu.ReportEvent(self.appname, id, cat, type, [msg])
+ except (KeyboardInterrupt, SystemExit):
+ raise
except:
self.handleError(record)
@@ -885,6 +889,8 @@ class HTTPHandler(logging.Handler):
if self.method == "POST":
h.send(data)
h.getreply() #can't do anything with the result
+ except (KeyboardInterrupt, SystemExit):
+ raise
except:
self.handleError(record)