[FIX] ir.mail_server: care for non-ascii connection error message

bzr revid: odo@openerp.com-20110914120644-u0e2dmo2n146nl97
This commit is contained in:
Olivier Dony
2011-09-14 14:06:44 +02:00
parent 8c17d42155
commit 623bdb2c9f
+1 -1
View File
@@ -189,7 +189,7 @@ class ir_mail_server(osv.osv):
password=smtp_server.smtp_pass, encryption=smtp_server.smtp_encryption,
smtp_debug=smtp_server.smtp_debug)
except Exception, e:
raise osv.except_osv(_("Connection test failed!"), _("Here is what we got instead:\n %s") % e)
raise osv.except_osv(_("Connection test failed!"), _("Here is what we got instead:\n %s") % tools.ustr(e))
finally:
try:
if smtp: smtp.quit()