vcl/source/app/scheduler.cxx |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 274e078a6e94e477b594839355cc709829d921dd
Author:     Mike Kaganski <mike.kagan...@collabora.com>
AuthorDate: Mon Dec 4 14:45:57 2023 +0300
Commit:     Mike Kaganski <mike.kagan...@collabora.com>
CommitDate: Mon Dec 4 17:26:37 2023 +0100

    Relax assertion a bit
    
    When running UITests on Windows with parallelism, I often see this
    assertion failing. I don't know why; but every time I attach the
    debugger to the failed process, I see mpSchedulerStack's mpTask
    and mpNext are both nullptr. The only place where this can happen
    is Task::~Task, which seems to suggest that this situation is
    basically the same as no mpSchedulerStack.
    
    Change-Id: I2485333944b6d56a365820bc4ca781098e508f48
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/160304
    Tested-by: Jenkins
    Reviewed-by: Mike Kaganski <mike.kagan...@collabora.com>

diff --git a/vcl/source/app/scheduler.cxx b/vcl/source/app/scheduler.cxx
index 098242fe6c70..e6893055f633 100644
--- a/vcl/source/app/scheduler.cxx
+++ b/vcl/source/app/scheduler.cxx
@@ -130,7 +130,7 @@ void Scheduler::ImplDeInitScheduler()
 #endif
     rSchedCtx.mbActive = false;
 
-    assert( nullptr == rSchedCtx.mpSchedulerStack );
+    assert( nullptr == rSchedCtx.mpSchedulerStack || 
(!rSchedCtx.mpSchedulerStack->mpTask && !rSchedCtx.mpSchedulerStack->mpNext) );
 
     if (rSchedCtx.mpSalTimer) rSchedCtx.mpSalTimer->Stop();
     delete rSchedCtx.mpSalTimer;

Reply via email to