[Libreoffice-commits] core.git: cppu/source

jan iversen jani at documentfoundation.org
Mon Nov 9 23:22:04 PST 2015


 cppu/source/uno/lbmap.cxx |    9 ++++++++-
 1 file changed, 8 insertions(+), 1 deletion(-)

New commits:
commit 6a2440ea91bb86cba74ecbb8afd520c8afa41ded
Author: jan iversen <jani at documentfoundation.org>
Date:   Mon Nov 9 19:30:30 2015 +0100

    cid#1338241 removed throw from C function.
    
    Lower level C++ make a throw, this cannot be passed
    back in a C function.
    
    Change-Id: I54ace0284d0291d54f53b8947e9f4ffc2e0a56ab
    Reviewed-on: https://gerrit.libreoffice.org/19873
    Tested-by: Jenkins <ci at libreoffice.org>
    Reviewed-by: Norbert Thiebaud <nthiebaud at gmail.com>

diff --git a/cppu/source/uno/lbmap.cxx b/cppu/source/uno/lbmap.cxx
index 51e1c26..82060fd 100644
--- a/cppu/source/uno/lbmap.cxx
+++ b/cppu/source/uno/lbmap.cxx
@@ -350,7 +350,14 @@ static inline bool loadModule(osl::Module & rModule, const OUString & rBridgeNam
 
     if (!bNeg)
     {
-        bool bModule = cppu::detail::loadModule(rModule, rBridgeName);
+        bool bModule;
+        try {
+            bModule = cppu::detail::loadModule(rModule, rBridgeName);
+        }
+        catch(...) {
+            // convert throw to return false
+            bModule = false;
+        }
 
         if (bModule)
             return true;


More information about the Libreoffice-commits mailing list