Fixed an issue in the Email config page testing the settings.

Fri, 28 Sep 2012 18:19:01 +0200

author
Detlev Offenbach <detlev@die-offenbachs.de>
date
Fri, 28 Sep 2012 18:19:01 +0200
changeset 2065
aea3ddf97aca
parent 2064
79cfe18963ae
child 2067
778e254ad4ee

Fixed an issue in the Email config page testing the settings.

Preferences/ConfigurationPages/EmailPage.py file | annotate | diff | comparison | revisions
--- a/Preferences/ConfigurationPages/EmailPage.py	Fri Sep 28 18:08:47 2012 +0200
+++ b/Preferences/ConfigurationPages/EmailPage.py	Fri Sep 28 18:19:01 2012 +0200
@@ -134,7 +134,10 @@
                 elif isinstance(e, socket.timeout):
                     errorStr = str(e)
                 elif isinstance(e, socket.error):
-                    errorStr = e[1]
+                    try:
+                        errorStr = e[1]
+                    except TypeError:
+                        errorStr = str(e)
                 else:
                     errorStr = str(e)
                 E5MessageBox.critical(self,
@@ -149,7 +152,10 @@
             elif isinstance(e, socket.timeout):
                 errorStr = str(e)
             elif isinstance(e, socket.error):
-                errorStr = e[1]
+                try:
+                    errorStr = e[1]
+                except TypeError:
+                    errorStr = str(e)
             else:
                 errorStr = str(e)
             E5MessageBox.critical(self,

eric ide

mercurial