From d69e830fb874582459134d483e7698d9dad805c6 Mon Sep 17 00:00:00 2001 From: Michael Meeks Date: Wed, 18 Jul 2018 12:23:10 +0100 Subject: Allow the comphelper threadpool to be reset after construction. Otherwise some pre-init components can start it, and threads get stranded in the forkit process causing grief. Change-Id: Ib1846f8b329b4c6b84645999dafba1252c5129c7 Reviewed-on: https://gerrit.libreoffice.org/57634 Reviewed-by: Jan Holesovsky Tested-by: Jan Holesovsky --- desktop/source/lib/init.cxx | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'desktop') diff --git a/desktop/source/lib/init.cxx b/desktop/source/lib/init.cxx index 60f6d5e0f18b..79e975ddbe6e 100644 --- a/desktop/source/lib/init.cxx +++ b/desktop/source/lib/init.cxx @@ -36,6 +36,7 @@ #include #include #include +#include #include #include @@ -3988,7 +3989,10 @@ static int lo_initialize(LibreOfficeKit* pThis, const char* pAppPath, const char } if (eStage == PRE_INIT) + { + comphelper::ThreadPool::getSharedOptimalPool().shutdown(); rtl_alloc_preInit(rtlAllocPostInit); + } return bInitialized; } -- cgit v1.2.3