[Libreoffice-commits] core.git: Branch 'distro/collabora/cp-5.3' - vcl/win
Mike Kaganski
mike.kaganski at collabora.com
Fri Jan 26 17:39:29 UTC 2018
vcl/win/app/salinst.cxx | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
New commits:
commit 1952332148ff351c21a198945fa76154d7e1f209
Author: Mike Kaganski <mike.kaganski at collabora.com>
Date: Sat Jul 15 11:37:22 2017 +0200
tdf#38915: don't wait on message queue if application already has quit.
Despite precautions in Application::Execute() and ImplYield(),
in my testing I sometimes see that soffice is waiting in
ImplSalYield()'s GetMessageW() when ImplGetSVData()->maAppData.mbAppQuit
is true, so that soffice.bin hangs in the background. I suspect
that this is related to the bug. Some obscure code path seems to
be able to get here after the flag is already set.
So, test also in ImplSalYield() right before GetMessageW() to
make sure. Another possibility is that we get here when the flag
is not set yet, and gets set while already waiting, but that would
mean this happens in a different thread.
Change-Id: Idb19eabcca8b5c24eac0ca76950edc1bf1e5bccb
Reviewed-on: https://gerrit.libreoffice.org/39996
Reviewed-by: Mike Kaganski <mike.kaganski at collabora.com>
Tested-by: Mike Kaganski <mike.kaganski at collabora.com>
(cherry picked from commit f054b9187155bc32b7d06808aea87127cb0a3a4f)
Reviewed-on: https://gerrit.libreoffice.org/48219
Reviewed-by: Aron Budea <aron.budea at collabora.com>
Tested-by: Aron Budea <aron.budea at collabora.com>
diff --git a/vcl/win/app/salinst.cxx b/vcl/win/app/salinst.cxx
index da67ca44582f..293ce2c2cc0b 100644
--- a/vcl/win/app/salinst.cxx
+++ b/vcl/win/app/salinst.cxx
@@ -598,7 +598,8 @@ ImplSalYield( bool bWait, bool bHandleAllCurrentEvents )
bOneEvent = false;
} while( --nMaxEvents && bOneEvent );
- if ( bWait && ! bWasMsg )
+ // Also check that we don't wait when application already has quit
+ if ( bWait && !bWasMsg && !ImplGetSVData()->maAppData.mbAppQuit )
{
if ( GetMessageW( &aMsg, nullptr, 0, 0 ) )
{
More information about the Libreoffice-commits
mailing list