aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--climl/imap.py7
1 files changed, 6 insertions, 1 deletions
diff --git a/climl/imap.py b/climl/imap.py
index 69e2117..6bdcb04 100644
--- a/climl/imap.py
+++ b/climl/imap.py
@@ -151,7 +151,12 @@ def main(callback=None):
time.sleep(10) # wait between retries
except KeyboardInterrupt:
break
- pass
except KeyboardInterrupt:
break
+ except Exception as e:
+ print('Unhandled exception during connection: ', e)
+ try:
+ time.sleep(10) # wait between retries
+ except KeyboardInterrupt:
+ break
print('end of connection')