cppu/source/uno/lbenv.cxx |   12 +++++++++---
 1 file changed, 9 insertions(+), 3 deletions(-)

New commits:
commit 5ff684477d7cb67a52223d555ae5f1341c6f8517
Author: jan iversen <j...@documentfoundation.org>
Date:   Mon Nov 9 19:13:57 2015 +0100

    cid#1338242 cid#1338241 removed throw from extern "C" function
    
    Encapsulated throw from C++ to a return false in the "C" function
    
    Change-Id: I2fc89b0dcf434395859300b3d3890247d1288295
    Reviewed-on: https://gerrit.libreoffice.org/19872
    Tested-by: Jenkins <c...@libreoffice.org>
    Reviewed-by: Norbert Thiebaud <nthieb...@gmail.com>

diff --git a/cppu/source/uno/lbenv.cxx b/cppu/source/uno/lbenv.cxx
index d036212..e1d294f 100644
--- a/cppu/source/uno/lbenv.cxx
+++ b/cppu/source/uno/lbenv.cxx
@@ -1050,10 +1050,16 @@ static bool loadEnv(OUString const  & cLibStem,
     // late init with some code from matching uno language binding
     // will be unloaded by environment
     osl::Module aMod;
-    bool bMod = cppu::detail::loadModule(aMod, cLibStem);
-
-    if (!bMod)
+    try {
+        bool bMod = cppu::detail::loadModule(aMod, cLibStem);
+        if (!bMod)
+            return false;
+    }
+    catch(...) {
+        // Catch everything and convert to return false
         return false;
+    }
+
 
     uno_initEnvironmentFunc fpInit = 
reinterpret_cast<uno_initEnvironmentFunc>(aMod.getSymbol(UNO_INIT_ENVIRONMENT));
 
_______________________________________________
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

Reply via email to