coverity#705110: use of invalid iterator

Change-Id: I13bb65892ffe09fa6f8bb70321e8846edcdc728c
This commit is contained in:
Markus Mohrhard 2013-03-01 06:16:28 +01:00
parent 2828fe2fd6
commit 03bbfe0a57

View File

@ -2553,7 +2553,7 @@ void SAL_CALL OStylesHelper::replaceByName( const ::rtl::OUString& aName, const
{
::osl::MutexGuard aGuard(m_aMutex);
TStyleElements::iterator aFind = m_aElements.find(aName);
if ( aFind != m_aElements.end() )
if ( aFind == m_aElements.end() )
throw container::NoSuchElementException();
if ( !aElement.isExtractableTo(m_aType) )
throw lang::IllegalArgumentException();