summaryrefslogtreecommitdiff
path: root/src/jwebmail/model
diff options
context:
space:
mode:
Diffstat (limited to 'src/jwebmail/model')
-rw-r--r--src/jwebmail/model/read_mails.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/jwebmail/model/read_mails.py b/src/jwebmail/model/read_mails.py
index d3887ca..e35299f 100644
--- a/src/jwebmail/model/read_mails.py
+++ b/src/jwebmail/model/read_mails.py
@@ -231,7 +231,9 @@ class QMailAuthuser:
popen.stdin.close()
inp = popen.stdout.readall()
- if popen.poll() is None:
+ try:
+ popen.wait(timeout=2)
+ except TimeoutExpired:
popen.kill()
popen.poll()