diff options
Diffstat (limited to 'sw/source/core/attr/calbck.cxx')
-rw-r--r-- | sw/source/core/attr/calbck.cxx | 23 |
1 files changed, 10 insertions, 13 deletions
diff --git a/sw/source/core/attr/calbck.cxx b/sw/source/core/attr/calbck.cxx index 7ad963da2f93..17aabca25f08 100644 --- a/sw/source/core/attr/calbck.cxx +++ b/sw/source/core/attr/calbck.cxx @@ -377,22 +377,19 @@ SwClientIter::SwClientIter( const SwModify& rModify ) SwClientIter::~SwClientIter() { - if( pClientIters ) + assert(pClientIters); + // reorganize list of ClientIters + if( pClientIters == this ) + pClientIters = pNxtIter; + else { - // reorganize list of ClientIters - if( pClientIters == this ) - pClientIters = pNxtIter; - else + SwClientIter* pTmp = pClientIters; + while( pTmp->pNxtIter != this ) { - SwClientIter* pTmp = pClientIters; - while( pTmp->pNxtIter != this ) - if( nullptr == ( pTmp = pTmp->pNxtIter ) ) - { - OSL_ENSURE( this, "Lost my pointer" ); - return ; - } - pTmp->pNxtIter = pNxtIter; + assert(pTmp); + pTmp = pTmp->pNxtIter; } + pTmp->pNxtIter = pNxtIter; } } |