summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNoel Grandin <noel@peralex.com>2021-02-04 08:44:45 +0200
committerChristian Lohmaier <lohmaier+LibreOffice@googlemail.com>2021-02-22 17:44:46 +0100
commitc8e38ba0a22caa52f9478060b459feaaa47214c0 (patch)
tree81f54ada8936a02a2a1bd5865f5b156b93db337f
parent44e809d887f5c694ebf9ba9a184ee748771abfdc (diff)
fix sporadic crash in sd_misc_tests on windows
we end up trying to process a timer message, but from inside the vcl de-init function, which means the timer stuff has already been de-initialised. Change-Id: I94703219754f1ccabd3065fc5ea437f39264197b Reviewed-on: https://gerrit.libreoffice.org/c/core/+/110397 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> (cherry picked from commit 14eff34dd10c047de222813eb16198b295b31d54) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/111314 Reviewed-by: Christian Lohmaier <lohmaier+LibreOffice@googlemail.com>
-rw-r--r--vcl/win/app/salinst.cxx6
1 files changed, 6 insertions, 0 deletions
diff --git a/vcl/win/app/salinst.cxx b/vcl/win/app/salinst.cxx
index 476b6350147a..c5a0c6fec04b 100644
--- a/vcl/win/app/salinst.cxx
+++ b/vcl/win/app/salinst.cxx
@@ -573,6 +573,12 @@ LRESULT CALLBACK SalComWndProc( HWND, UINT nMsg, WPARAM wParam, LPARAM lParam, b
SAL_INFO("vcl.gdi.wndproc", "SalComWndProc(nMsg=" << nMsg << ", wParam=" << wParam
<< ", lParam=" << lParam << "); inSendMsg: " << bIsOtherThreadMessage);
+ if (ImplGetSVData()->mbDeInit)
+ {
+ SAL_WARN("vcl.gdi.wndproc", "ignoring timer event because we are shutting down");
+ return 0;
+ }
+
switch ( nMsg )
{
case SAL_MSG_THREADYIELD: