mirror of
https://github.com/chatmail/core.git
synced 2026-05-08 17:36:29 +03:00
fix(python): add more checks for _thread_quitflag
This commit is contained in:
@@ -605,23 +605,28 @@ class IOThreads:
|
|||||||
self._log_event("py-bindings-info", 0, "MVBOX THREAD START")
|
self._log_event("py-bindings-info", 0, "MVBOX THREAD START")
|
||||||
while not self._thread_quitflag:
|
while not self._thread_quitflag:
|
||||||
lib.dc_perform_mvbox_jobs(self._dc_context)
|
lib.dc_perform_mvbox_jobs(self._dc_context)
|
||||||
lib.dc_perform_mvbox_fetch(self._dc_context)
|
if not self._thread_quitflag:
|
||||||
lib.dc_perform_mvbox_idle(self._dc_context)
|
lib.dc_perform_mvbox_fetch(self._dc_context)
|
||||||
|
if not self._thread_quitflag:
|
||||||
|
lib.dc_perform_mvbox_idle(self._dc_context)
|
||||||
self._log_event("py-bindings-info", 0, "MVBOX THREAD FINISHED")
|
self._log_event("py-bindings-info", 0, "MVBOX THREAD FINISHED")
|
||||||
|
|
||||||
def sentbox_thread_run(self):
|
def sentbox_thread_run(self):
|
||||||
self._log_event("py-bindings-info", 0, "SENTBOX THREAD START")
|
self._log_event("py-bindings-info", 0, "SENTBOX THREAD START")
|
||||||
while not self._thread_quitflag:
|
while not self._thread_quitflag:
|
||||||
lib.dc_perform_sentbox_jobs(self._dc_context)
|
lib.dc_perform_sentbox_jobs(self._dc_context)
|
||||||
lib.dc_perform_sentbox_fetch(self._dc_context)
|
if not self._thread_quitflag:
|
||||||
lib.dc_perform_sentbox_idle(self._dc_context)
|
lib.dc_perform_sentbox_fetch(self._dc_context)
|
||||||
|
if not self._thread_quitflag:
|
||||||
|
lib.dc_perform_sentbox_idle(self._dc_context)
|
||||||
self._log_event("py-bindings-info", 0, "SENTBOX THREAD FINISHED")
|
self._log_event("py-bindings-info", 0, "SENTBOX THREAD FINISHED")
|
||||||
|
|
||||||
def smtp_thread_run(self):
|
def smtp_thread_run(self):
|
||||||
self._log_event("py-bindings-info", 0, "SMTP THREAD START")
|
self._log_event("py-bindings-info", 0, "SMTP THREAD START")
|
||||||
while not self._thread_quitflag:
|
while not self._thread_quitflag:
|
||||||
lib.dc_perform_smtp_jobs(self._dc_context)
|
lib.dc_perform_smtp_jobs(self._dc_context)
|
||||||
lib.dc_perform_smtp_idle(self._dc_context)
|
if not self._thread_quitflag:
|
||||||
|
lib.dc_perform_smtp_idle(self._dc_context)
|
||||||
self._log_event("py-bindings-info", 0, "SMTP THREAD FINISHED")
|
self._log_event("py-bindings-info", 0, "SMTP THREAD FINISHED")
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user