- Added more debug output if an error occurs when sending mail. Thanks to Stephen Gildea

git-svn-id: https://fail2ban.svn.sourceforge.net/svnroot/fail2ban/branches/FAIL2BAN-0_5@190 a942ae1a-1317-0410-a47c-b1dcaea8d605
0.5
Cyril Jaquier 2005-09-08 18:05:59 +00:00
parent c1a86f9e18
commit 830ac2001e
1 changed files with 2 additions and 2 deletions

View File

@ -64,8 +64,8 @@ class Mail:
server.sendmail(self.fromAddr, self.toAddr, mail)
logSys.debug("Email sent to " + `self.toAddr`)
server.quit()
except Exception:
except Exception, e:
logSys.error("Unable to send mail to " + self.host + ":" +
`self.port` + " from " + self.fromAddr + " to " +
`self.toAddr`)
`self.toAddr` + ": " + `e` + ": " + `e.args`)