From 324e2a5c3e6355e6b38db0add100465224841364 Mon Sep 17 00:00:00 2001 From: Michael Weghorn Date: Fri, 5 Nov 2021 14:00:31 +0100 Subject: tdf#144994 QtInstance::CreateMenu needs SolarMutex It can be called from extensions (as is the case e.g. for LanguageTool, s. tdf#144994 comment 19; assertion is hit after clicking around in the menu a bit) and 'RunInMainThread' requires that the SolarMutex is held. Change-Id: I282ef6a21e60b636abb27aeba332ae3a634ce680 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/124750 Tested-by: Jenkins Reviewed-by: Michael Weghorn --- vcl/qt5/QtInstance.cxx | 1 + 1 file changed, 1 insertion(+) diff --git a/vcl/qt5/QtInstance.cxx b/vcl/qt5/QtInstance.cxx index 06840ad7281f..29a7d0e4ddf7 100644 --- a/vcl/qt5/QtInstance.cxx +++ b/vcl/qt5/QtInstance.cxx @@ -358,6 +358,7 @@ QtInstance::CreateVirtualDevice(SalGraphics& rGraphics, tools::Long& nDX, tools: std::unique_ptr QtInstance::CreateMenu(bool bMenuBar, Menu* pVCLMenu) { + SolarMutexGuard aGuard; std::unique_ptr pRet; RunInMainThread([&pRet, bMenuBar, pVCLMenu]() { QtMenu* pSalMenu = new QtMenu(bMenuBar); -- cgit