[Libreoffice-commits] core.git: include/vcl

Libreoffice Gerrit user logerrit at kemper.freedesktop.org
Wed Feb 27 10:53:54 UTC 2019


 include/vcl/threadex.hxx |   10 ++++++++++
 1 file changed, 10 insertions(+)

New commits:
commit d34c0852d73b1b02115cc6c469106fabd057dbb7
Author:     Stephan Bergmann <sbergman at redhat.com>
AuthorDate: Wed Feb 27 09:44:37 2019 +0100
Commit:     Stephan Bergmann <sbergman at redhat.com>
CommitDate: Wed Feb 27 11:53:29 2019 +0100

    Fix GenericSolarThreadExecutor<...,void> specialization
    
    Change-Id: I4468a3a8d036ca4894ba7977f6654244552464aa
    Reviewed-on: https://gerrit.libreoffice.org/68423
    Tested-by: Jenkins
    Reviewed-by: Stephan Bergmann <sbergman at redhat.com>

diff --git a/include/vcl/threadex.hxx b/include/vcl/threadex.hxx
index cac25bc58b75..cd511f271d2c 100644
--- a/include/vcl/threadex.hxx
+++ b/include/vcl/threadex.hxx
@@ -92,6 +92,16 @@ private:
 template <typename FuncT>
 class GenericSolarThreadExecutor<FuncT, void> : public SolarThreadExecutor
 {
+public:
+    static void exec( FuncT const& func )
+    {
+        typedef GenericSolarThreadExecutor<FuncT, void> ExecutorT;
+        ::std::unique_ptr<ExecutorT> const pExecutor( new ExecutorT(func) );
+        pExecutor->execute();
+        if (pExecutor->m_exc)
+            std::rethrow_exception(pExecutor->m_exc);
+    }
+
 private:
     explicit GenericSolarThreadExecutor( FuncT const& func )
         : m_func(func) {}


More information about the Libreoffice-commits mailing list