diff --git a/libs/lib/xaal/lib/aioengine.py b/libs/lib/xaal/lib/aioengine.py
index 36a59d7583c701e3c3065d1d42ca09b59b2d1773..c5c1855aa132e91c0900e2ffb9beb88aa5187f2e 100644
--- a/libs/lib/xaal/lib/aioengine.py
+++ b/libs/lib/xaal/lib/aioengine.py
@@ -268,7 +268,7 @@ class AsyncEngine(core.EngineMixin):
         self.started_event.clear()
         # cancel all tasks
         for task in self.all_tasks():
-            if task != self._watchdog_task:
+            if task != self._watchdog_task and not task.cancelled():
                 task.cancel()
 
     def sigkill_handler(self, signal, frame):