summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndrzej J.R. Hunt <andrzej@ahunt.org>2013-08-02 14:41:36 +0200
committerAndrzej J.R. Hunt <andrzej@ahunt.org>2013-08-02 15:39:52 +0200
commitcc1e1e9509dd78d043c4b2f345df84635bc7492a (patch)
tree3f96d51d9436ffcd11d11f9bb9ae497028aef278
parent03528afc5c21350b064d6a43fc57f1adc1c94c41 (diff)
Only write db to file if we are embedded. (firebird-sdbc)
Change-Id: If6126a8005d666c0c1355efc2a887519da37c891
-rw-r--r--connectivity/source/drivers/firebird/Connection.cxx5
1 files changed, 5 insertions, 0 deletions
diff --git a/connectivity/source/drivers/firebird/Connection.cxx b/connectivity/source/drivers/firebird/Connection.cxx
index 02beb6b73fa5..07b16ebe6fc3 100644
--- a/connectivity/source/drivers/firebird/Connection.cxx
+++ b/connectivity/source/drivers/firebird/Connection.cxx
@@ -610,6 +610,11 @@ void SAL_CALL OConnection::clearWarnings( ) throw(SQLException, RuntimeExceptio
void SAL_CALL OConnection::documentEventOccured( const DocumentEvent& _Event )
throw(RuntimeException)
{
+ MutexGuard aGuard(m_aMutex);
+
+ if (!m_bIsEmbedded)
+ return;
+
if (_Event.EventName == "OnSave" || _Event.EventName == "OnSaveAs")
{
commit(); // Commit and close transaction