[Libreoffice-commits] .: forms/source

David Tardon dtardon at kemper.freedesktop.org
Fri Apr 1 00:52:25 PDT 2011


 forms/source/xforms/propertysetbase.cxx |   10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)

New commits:
commit e268c11222b09b222648f06e2b6d15b855a65acb
Author: David Tardon <dtardon at redhat.com>
Date:   Wed Mar 30 06:17:50 2011 +0200

    convert DBG_ assertions to OSL_

diff --git a/forms/source/xforms/propertysetbase.cxx b/forms/source/xforms/propertysetbase.cxx
index 9e771f4..1c18889 100644
--- a/forms/source/xforms/propertysetbase.cxx
+++ b/forms/source/xforms/propertysetbase.cxx
@@ -80,7 +80,7 @@ cppu::IPropertyArrayHelper& SAL_CALL PropertySetBase::getInfoHelper()
 {
     if ( !m_pProperties )
     {
-        DBG_ASSERT( !m_aProperties.empty(), "PropertySetBase::getInfoHelper: no registered properties!" );
+        OSL_ENSURE( !m_aProperties.empty(), "PropertySetBase::getInfoHelper: no registered properties!" );
         m_pProperties = new cppu::OPropertyArrayHelper( &m_aProperties[0], m_aProperties.size(), sal_False );
     }
     return *m_pProperties;
@@ -94,10 +94,10 @@ Reference< XPropertySetInfo > SAL_CALL PropertySetBase::getPropertySetInfo(  ) t
 void PropertySetBase::registerProperty( const Property& rProperty,
     const ::rtl::Reference< PropertyAccessorBase >& rAccessor )
 {
-    DBG_ASSERT( rAccessor.get(), "PropertySetBase::registerProperty: invalid property accessor, this will crash!" );
+    OSL_ENSURE( rAccessor.get(), "PropertySetBase::registerProperty: invalid property accessor, this will crash!" );
     m_aAccessors.insert( PropertyAccessors::value_type( rProperty.Handle, rAccessor ) );
 
-    DBG_ASSERT( ( rAccessor->isWriteable() == true )
+    OSL_ENSURE( ( rAccessor->isWriteable() == true )
                 == ( ( rProperty.Attributes & com::sun::star::beans::PropertyAttribute::READONLY ) == 0 ),
         "PropertySetBase::registerProperty: inconsistence!" );
 
@@ -149,13 +149,13 @@ void PropertySetBase::initializePropertyValueCache( sal_Int32 nHandle )
     ::std::pair< PropertyValueCache::iterator, bool > aInsertResult =
 #endif
     m_aCache.insert( PropertyValueCache::value_type( nHandle, aCurrentValue ) );
-    DBG_ASSERT( aInsertResult.second, "PropertySetBase::initializePropertyValueCache: already cached a value for this property!" );
+    OSL_ENSURE( aInsertResult.second, "PropertySetBase::initializePropertyValueCache: already cached a value for this property!" );
 }
 
 PropertyAccessorBase& PropertySetBase::locatePropertyHandler( sal_Int32 nHandle ) const
 {
     PropertyAccessors::const_iterator aPropertyPos = m_aAccessors.find( nHandle );
-    DBG_ASSERT( aPropertyPos != m_aAccessors.end() && aPropertyPos->second.get(),
+    OSL_ENSURE( aPropertyPos != m_aAccessors.end() && aPropertyPos->second.get(),
         "PropertySetBase::locatePropertyHandler: accessor map is corrupted!" );
         // neither should this be called for handles where there is no accessor, nor should a
         // NULL accssor be in the map


More information about the Libreoffice-commits mailing list