diff options
author | Ivan Timofeev <timofeev.i.s@gmail.com> | 2011-11-06 13:20:56 +0400 |
---|---|---|
committer | Ivan Timofeev <timofeev.i.s@gmail.com> | 2011-11-06 15:47:55 +0400 |
commit | 5122e3413b06125ff45fd10e1ac1f0e58c24afcc (patch) | |
tree | 1bb7587279c702c3479ceb746c6ef449726a4948 /starmath | |
parent | 0cf754f5ca356c2d93f7ebf8523b2dc2246e4763 (diff) |
cppcheck: avoid possible null pointer dereferences
Diffstat (limited to 'starmath')
-rw-r--r-- | starmath/source/unomodel.cxx | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/starmath/source/unomodel.cxx b/starmath/source/unomodel.cxx index 4ac92976567e..fae257901e07 100644 --- a/starmath/source/unomodel.cxx +++ b/starmath/source/unomodel.cxx @@ -882,9 +882,9 @@ void SmModel::_getPropertyValues( const PropertyMapEntry **ppEntries, Any *pValu for (size_t i = 0; i < aSymbols.size(); ++i) { const SmSym * pSymbol = aSymbols[ i ]; - const bool bIsUsedSymbol = rUsedSymbols.find( pSymbol->GetName() ) != rUsedSymbols.end(); if (pSymbol && !pSymbol->IsPredefined() && - (!bUsedSymbolsOnly || bIsUsedSymbol)) + (!bUsedSymbolsOnly || + rUsedSymbols.find( pSymbol->GetName() ) != rUsedSymbols.end())) { aVector.push_back ( pSymbol ); nCount++; |