sw/source/core/doc/docnew.cxx | 1 + sw/source/uibase/dbui/dbmgr.cxx | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-)
New commits: commit cbdf020b558c217b9bcbb7396deb99f9dee71e3a Author: Szymon KÅos <szymon.k...@collabora.com> Date: Mon Sep 25 19:04:05 2017 +0200 tdf#112634 Don't remove embedded database before close Change-Id: Iaa60160d40b0f7b5dceba319bc3813d124c34cc1 Reviewed-on: https://gerrit.libreoffice.org/42762 Tested-by: Jenkins <c...@libreoffice.org> Reviewed-by: Szymon KÅos <szymon.k...@collabora.com> (cherry picked from commit 79a425900e31bda83cde1bee150c1234931cb8bd) Reviewed-on: https://gerrit.libreoffice.org/42844 Reviewed-by: Andras Timar <andras.ti...@collabora.com> Tested-by: Andras Timar <andras.ti...@collabora.com> diff --git a/sw/source/core/doc/docnew.cxx b/sw/source/core/doc/docnew.cxx index d20203002e16..daa75ee4f510 100644 --- a/sw/source/core/doc/docnew.cxx +++ b/sw/source/core/doc/docnew.cxx @@ -530,6 +530,7 @@ SwDoc::~SwDoc() // Remove the revoke listener here first, so that we don't remove the data source from the document. mpDBManager->releaseRevokeListener(); SwDBManager::RevokeDataSource(maDBData.sDataSource); + SwDBManager::RevokeDataSource(mpDBManager->getEmbeddedName()); } else if (!mpDBManager->getEmbeddedName().isEmpty()) { diff --git a/sw/source/uibase/dbui/dbmgr.cxx b/sw/source/uibase/dbui/dbmgr.cxx index 838e0fa0888d..d469691cbe23 100644 --- a/sw/source/uibase/dbui/dbmgr.cxx +++ b/sw/source/uibase/dbui/dbmgr.cxx @@ -3245,7 +3245,7 @@ void SwDBManager::CommitLastRegistrations() { for (auto aIt = m_aUncommitedRegistrations.begin(); aIt != m_aUncommitedRegistrations.end();) { - if (aIt->first == m_pDoc->GetDocShell()) + if (aIt->first == m_pDoc->GetDocShell() || aIt->first == nullptr) { m_aNotUsedConnections.push_back(aIt->second); aIt = m_aUncommitedRegistrations.erase(aIt);
_______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits