Tag: cws_src680_dba201d User: fs Date: 05/10/06 23:08:21 Modified: /dba/dbaccess/source/core/dataaccess/ ModelImpl.cxx
Log: also dispose m_pStorageAccess when the model is disposed (was a resource leak) File Changes: Directory: /dba/dbaccess/source/core/dataaccess/ ================================================ File [changed]: ModelImpl.cxx Url: http://dba.openoffice.org/source/browse/dba/dbaccess/source/core/dataaccess/ModelImpl.cxx?r1=1.7&r2=1.7.10.1 Delta lines: +21 -4 -------------------- --- ModelImpl.cxx 8 Sep 2005 10:14:25 -0000 1.7 +++ ModelImpl.cxx 7 Oct 2005 06:08:09 -0000 1.7.10.1 @@ -4,9 +4,9 @@ * * $RCSfile: ModelImpl.cxx,v $ * - * $Revision: 1.7 $ + * $Revision: 1.7.10.1 $ * - * last change: $Author: rt $ $Date: 2005/09/08 10:14:25 $ + * last change: $Author: fs $ $Date: 2005/10/07 06:08:09 $ * * The Contents of this file are made available subject to * the terms of GNU Lesser General Public License Version 2.1. @@ -343,6 +343,16 @@ ODatabaseModelImpl* pImpl = m_pModelImplementation; if ( pImpl ) pImpl->disposing( Source ); + + for ( NamedStorages::iterator find = m_aExposedStorages.begin(); + find != m_aExposedStorages.end(); + ++find + ) + if ( find->second == Source.Source ) + { + m_aExposedStorages.erase( find ); + break; + } } //============================================================ @@ -531,6 +541,13 @@ { } m_xStorage = NULL; + + if ( m_pStorageAccess ) + { + m_pStorageAccess->dispose(); + m_pStorageAccess->release(); + m_pStorageAccess = NULL; + } } // ----------------------------------------------------------------------------- const Reference< XNumberFormatsSupplier > & ODatabaseModelImpl::getNumberFormatsSupplier() --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
