Kaydet (Commit) 9beae152 authored tarafından Michael Stahl's avatar Michael Stahl

xmloff: convert legacy assertions in SvXMLAutoStylePoolP_Impl::exportXML

Change-Id: I9f21ad73a8a30e0b9d0d515713cc95b303f973f7
üst ce0ed76f
...@@ -484,7 +484,7 @@ void SvXMLAutoStylePoolP_Impl::GetRegisteredNames( ...@@ -484,7 +484,7 @@ void SvXMLAutoStylePoolP_Impl::GetRegisteredNames(
} }
// copy the families + names into the sequence types // copy the families + names into the sequence types
DBG_ASSERT( aFamilies.size() == aNames.size(), "families != names" ); assert(aFamilies.size() == aNames.size());
rFamilies.realloc( aFamilies.size() ); rFamilies.realloc( aFamilies.size() );
std::copy( aFamilies.begin(), aFamilies.end(), rFamilies.getArray() ); std::copy( aFamilies.begin(), aFamilies.end(), rFamilies.getArray() );
...@@ -638,15 +638,10 @@ void SvXMLAutoStylePoolP_Impl::exportXML( ...@@ -638,15 +638,10 @@ void SvXMLAutoStylePoolP_Impl::exportXML(
XMLAutoStylePoolProperties* pProperties = XMLAutoStylePoolProperties* pProperties =
&rParent.GetPropertiesList()[j]; &rParent.GetPropertiesList()[j];
sal_uLong nPos = pProperties->GetPos(); sal_uLong nPos = pProperties->GetPos();
DBG_ASSERT( nPos < nCount, assert(nPos < nCount);
"SvXMLAutoStylePool_Impl::exportXML: wrong position" ); assert(!aExpStyles[nPos].mpProperties);
if( nPos < nCount ) aExpStyles[nPos].mpProperties = pProperties;
{ aExpStyles[nPos].mpParent = &rParent.GetParent();
DBG_ASSERT( !aExpStyles[nPos].mpProperties,
"SvXMLAutoStylePool_Impl::exportXML: double position" );
aExpStyles[nPos].mpProperties = pProperties;
aExpStyles[nPos].mpParent = &rParent.GetParent();
}
} }
} }
...@@ -674,8 +669,7 @@ void SvXMLAutoStylePoolP_Impl::exportXML( ...@@ -674,8 +669,7 @@ void SvXMLAutoStylePoolP_Impl::exportXML(
for( size_t i = 0; i < nCount; i++ ) for( size_t i = 0; i < nCount; i++ )
{ {
DBG_ASSERT( aExpStyles[i].mpProperties, assert(aExpStyles[i].mpProperties);
"SvXMLAutoStylePool_Impl::exportXML: empty position" );
if( aExpStyles[i].mpProperties ) if( aExpStyles[i].mpProperties )
{ {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment