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

Stephan Bergmann sbergman at redhat.com
Wed Dec 18 23:44:30 PST 2013


 include/osl/module.hxx |    9 +++++++++
 1 file changed, 9 insertions(+)

New commits:
commit 80d977b896904a0261d32857469c1b3e7516ca1e
Author: Stephan Bergmann <sbergman at redhat.com>
Date:   Thu Dec 19 08:43:57 2013 +0100

    Introduce osl::Module::release
    
    ...to make osl::Module useful in cases where there underlying library shall
    remain loaded after the Module instance is destroyed.
    
    Change-Id: Ie2c9c094207f159b900620d394f489d49ffa36d2

diff --git a/include/osl/module.hxx b/include/osl/module.hxx
index 98cd1e3..e78ff88 100644
--- a/include/osl/module.hxx
+++ b/include/osl/module.hxx
@@ -163,6 +163,15 @@ public:
         return m_Module;
     }
 
+    /** Release the module so that it will not be unloaded from the destructor.
+
+        This instance returns to the state of a default-constructed instance
+        again.
+
+        @since LibreOffice 4.3
+    */
+    void release() { m_Module = 0; }
+
 private:
     oslModule m_Module;
 


More information about the Libreoffice-commits mailing list