Kaydet (Commit) 0c8a3a82 authored tarafından Caolán McNamara's avatar Caolán McNamara

coverity#1202778 Logically dead code

Change-Id: Ie3f297bb5bf05bb133d964ddfe4d4f16af1eb73f
üst 9a8e6c71
...@@ -40,11 +40,12 @@ static const WordDialogTable aWordDialogTable[] = ...@@ -40,11 +40,12 @@ static const WordDialogTable aWordDialogTable[] =
OUString OUString
SwVbaDialog::mapIndexToName( sal_Int32 nIndex ) SwVbaDialog::mapIndexToName( sal_Int32 nIndex )
{ {
for( const WordDialogTable* pTable = aWordDialogTable; pTable != NULL; pTable++ ) for (size_t i = 0; i < SAL_N_ELEMENTS(aWordDialogTable); ++i)
{ {
if( nIndex == pTable->wdDialog ) const WordDialogTable& rTable = aWordDialogTable[i];
if( nIndex == rTable.wdDialog )
{ {
return OUString::createFromAscii( pTable->ooDialog ); return OUString::createFromAscii( rTable.ooDialog );
} }
} }
return OUString(); return OUString();
......
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