[Libreoffice-commits] core.git: 2 commits - dbaccess/source
Lionel Elie Mamane
lionel at mamane.lu
Mon Dec 2 14:57:58 PST 2013
dbaccess/source/core/api/RowSet.cxx | 8 ++++++--
1 file changed, 6 insertions(+), 2 deletions(-)
New commits:
commit 56cdaa186971eedbac1b494b46c2622862386e1a
Author: Lionel Elie Mamane <lionel at mamane.lu>
Date: Mon Dec 2 23:55:43 2013 +0100
fdo#72163 belts and suspenders
1) Do not dispose m_xComposer, might still be used by our m_pCache
2) Do not create a new m_xComposer if the previous one will do, so
that we do not gratiously use a different one than our m_pCache.
Change-Id: I6540c035c9159017c694b36e676721ec3e42db51
diff --git a/dbaccess/source/core/api/RowSet.cxx b/dbaccess/source/core/api/RowSet.cxx
index 69663d0..f2c4345 100644
--- a/dbaccess/source/core/api/RowSet.cxx
+++ b/dbaccess/source/core/api/RowSet.cxx
@@ -2250,12 +2250,14 @@ sal_Bool ORowSet::impl_initComposer_throw( OUString& _out_rCommandToExecute )
if ( !bUseEscapeProcessing )
return bUseEscapeProcessing;
+ if (m_bCommandFacetsDirty)
+ m_xComposer = NULL;
+
Reference< XMultiServiceFactory > xFactory( m_xActiveConnection, UNO_QUERY );
- if ( xFactory.is() )
+ if ( !m_xComposer.is() && xFactory.is() )
{
try
{
- ::comphelper::disposeComponent( m_xComposer );
m_xComposer.set( xFactory->createInstance( SERVICE_NAME_SINGLESELECTQUERYCOMPOSER ), UNO_QUERY_THROW );
}
catch (const Exception& ) { m_xComposer = NULL; }
commit d4b7e3d12a02d27e9ea569e4828370cf00e17540
Author: Lionel Elie Mamane <lionel at mamane.lu>
Date: Mon Dec 2 23:44:11 2013 +0100
fdo#72163 after updating m_xComposer, command facets are not dirty anymore
Else we dispose m_xComposer too eagerly; still used by m_pCacheSet.
Change-Id: I205488465c19a356534df17b8a5e9a20ce6766c9
diff --git a/dbaccess/source/core/api/RowSet.cxx b/dbaccess/source/core/api/RowSet.cxx
index dde6444..69663d0 100644
--- a/dbaccess/source/core/api/RowSet.cxx
+++ b/dbaccess/source/core/api/RowSet.cxx
@@ -2290,6 +2290,8 @@ sal_Bool ORowSet::impl_initComposer_throw( OUString& _out_rCommandToExecute )
_out_rCommandToExecute = m_xComposer->getQueryWithSubstitution();
+ m_bCommandFacetsDirty = sal_False;
+
return bUseEscapeProcessing;
}
More information about the Libreoffice-commits
mailing list