diff options
author | Tomaž Vajngerl <tomaz.vajngerl@collabora.co.uk> | 2018-11-29 21:53:48 +0100 |
---|---|---|
committer | Tomaž Vajngerl <quikee@gmail.com> | 2018-12-01 09:07:33 +0100 |
commit | d7a88b902af983145b196990949e89420e5bc4cf (patch) | |
tree | bda0eff46496f58a477d0dbcbb29abee0125fab3 /desktop/source | |
parent | d69edca3e004ab8669b3363b4755da8bb42f62fc (diff) |
Add SolarMutexGuard where needed
When triggering rechecking of signature status, an assert fails and
brings down the program because we don't hold a SolarMutex. The
rechecking of signature status needs to broadcasts.
Change-Id: Ib500b06d2e191465df1e0da2097ddb1b6b06725a
Reviewed-on: https://gerrit.libreoffice.org/64292
Tested-by: Jenkins
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
Diffstat (limited to 'desktop/source')
-rw-r--r-- | desktop/source/lib/init.cxx | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/desktop/source/lib/init.cxx b/desktop/source/lib/init.cxx index d96c7737157d..f235728e65bb 100644 --- a/desktop/source/lib/init.cxx +++ b/desktop/source/lib/init.cxx @@ -3802,6 +3802,8 @@ static bool doc_insertCertificate(LibreOfficeKitDocument* pThis, if (!xCertificate.is()) return false; + SolarMutexGuard aGuard; + return pObjectShell->SignDocumentContentUsingCertificate(xCertificate); } @@ -3879,6 +3881,8 @@ static int doc_getSignatureState(LibreOfficeKitDocument* pThis) if (!pObjectShell) return int(SignatureState::UNKNOWN); + SolarMutexGuard aGuard; + pObjectShell->RecheckSignature(false); return int(pObjectShell->GetDocumentSignatureState()); |