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

Lionel Elie Mamane lionel at mamane.lu
Thu Jun 2 09:53:56 UTC 2016


 connectivity/source/drivers/firebird/Connection.cxx |    7 +++++--
 1 file changed, 5 insertions(+), 2 deletions(-)

New commits:
commit 09224f23168786fbe28641a87cbffddcbed6e31b
Author: Lionel Elie Mamane <lionel at mamane.lu>
Date:   Thu Jun 2 11:52:42 2016 +0200

    don't detach from database if we are not attached
    
    this leads to a cascade of uncaught/unexpected exception and thus abort in debug build
    
    Change-Id: If417d2fd2037379e3006f98bc046713729ea4648

diff --git a/connectivity/source/drivers/firebird/Connection.cxx b/connectivity/source/drivers/firebird/Connection.cxx
index 4f82570..979c677 100644
--- a/connectivity/source/drivers/firebird/Connection.cxx
+++ b/connectivity/source/drivers/firebird/Connection.cxx
@@ -773,9 +773,12 @@ void Connection::disposing()
         isc_rollback_transaction(status, &m_aTransactionHandle);
     }
 
-    if (isc_detach_database(status, &m_aDBHandle))
+    if (m_aDBHandle != 0)
     {
-        evaluateStatusVector(status, "isc_detach_database", *this);
+        if (isc_detach_database(status, &m_aDBHandle))
+        {
+            evaluateStatusVector(status, "isc_detach_database", *this);
+        }
     }
     // TODO: write to storage again?
 


More information about the Libreoffice-commits mailing list