IMAP IDLE cleanup(4): Simplify code
while True: if a: return is equivalent to while not a: Signed-off-by: Sebastian Spaeth <Sebastian@SSpaeth.de> Signed-off-by: Nicolas Sebrecht <nicolas.s-dev@laposte.net>
This commit is contained in:
parent
6ad0de08ef
commit
59753fc06f
@ -514,9 +514,7 @@ class IdleThread(object):
|
|||||||
self.imapaborted = True
|
self.imapaborted = True
|
||||||
self.stop()
|
self.stop()
|
||||||
|
|
||||||
while True:
|
while not self.stop_sig.isSet():
|
||||||
if self.stop_sig.isSet():
|
|
||||||
return
|
|
||||||
self.needsync = False
|
self.needsync = False
|
||||||
self.imapaborted = False
|
self.imapaborted = False
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user