diff options
author | Michael Stahl <mstahl@redhat.com> | 2015-05-18 13:44:38 +0200 |
---|---|---|
committer | Michael Stahl <mstahl@redhat.com> | 2015-05-18 14:49:16 +0200 |
commit | 466f543825223388e75b03a628977ba95ae71c2e (patch) | |
tree | f3e08b8f5380f74bc4a82857862e2e720c97cc90 /xmloff | |
parent | 227be0d87edcc3b92b90ccb4c0678d376d1dd6d4 (diff) |
xmloff: convert legacy asserts in SvXMLStylesContext_Impl
Change-Id: Ib9caf65f8cf1dc4ef9729f178fbe4ed032437be2
Diffstat (limited to 'xmloff')
-rw-r--r-- | xmloff/source/style/xmlstyle.cxx | 18 |
1 files changed, 8 insertions, 10 deletions
diff --git a/xmloff/source/style/xmlstyle.cxx b/xmloff/source/style/xmlstyle.cxx index 93ede0727a19..bd3290991b3e 100644 --- a/xmloff/source/style/xmlstyle.cxx +++ b/xmloff/source/style/xmlstyle.cxx @@ -255,8 +255,8 @@ class SvXMLStylesContext_Impl mutable IndicesType* pIndices; bool bAutomaticStyle; -#ifdef DBG_UTIL - mutable sal_uInt32 nIndexCreated; +#if OSL_DEBUG_LEVEL > 0 + mutable sal_uInt32 m_nIndexCreated; #endif void FlushIndex() { delete pIndices; pIndices = 0; } @@ -284,8 +284,8 @@ public: SvXMLStylesContext_Impl::SvXMLStylesContext_Impl( bool bAuto ) : pIndices( 0 ), bAutomaticStyle( bAuto ) -#ifdef DBG_UTIL -, nIndexCreated( 0 ) +#if OSL_DEBUG_LEVEL > 0 + , m_nIndexCreated( 0 ) #endif {} @@ -329,14 +329,12 @@ const SvXMLStyleContext *SvXMLStylesContext_Impl::FindStyleChildContext( sal_uIn if( !pIndices && bCreateIndex && !aStyles.empty() ) { -#ifdef DBG_UTIL - DBG_ASSERT( 0==nIndexCreated, - "Performance warning: sdbcx::Index created multiple times" ); -#endif + SAL_WARN_IF(0 != m_nIndexCreated, "xmloff.style", + "Performance warning: sdbcx::Index created multiple times"); pIndices = new IndicesType(aStyles.begin(), aStyles.end()); SAL_WARN_IF(pIndices->size() != aStyles.size(), "xmloff", "Here is a duplicate Style"); -#ifdef DBG_UTIL - ++nIndexCreated; +#if OSL_DEBUG_LEVEL > 0 + ++m_nIndexCreated; #endif } |