coverity#1132660 Dereference after null check

Change-Id: Ib184d73f2ced3beca8540a37bab74c4a712170ba
This commit is contained in:
Norbert Thiebaud
2014-01-19 14:59:29 -06:00
parent 989c7ce9a8
commit 014a0e5d6f

View File

@@ -427,7 +427,6 @@ namespace accessibility
return AccessibleRole::TREE_ITEM; return AccessibleRole::TREE_ITEM;
else if( nType == TREEBOX_ALLITEM_ACCROLE_TYPE_LIST) else if( nType == TREEBOX_ALLITEM_ACCROLE_TYPE_LIST)
return AccessibleRole::LIST_ITEM; return AccessibleRole::LIST_ITEM;
}
sal_uInt16 treeFlag = pBox->GetTreeFlags(); sal_uInt16 treeFlag = pBox->GetTreeFlags();
if(treeFlag & TREEFLAG_CHKBTN ) if(treeFlag & TREEFLAG_CHKBTN )
@@ -444,15 +443,13 @@ namespace accessibility
return AccessibleRole::LABEL; return AccessibleRole::LABEL;
} }
} }
else
{
if(getRoleType() == 0) if(getRoleType() == 0)
return AccessibleRole::LIST_ITEM; return AccessibleRole::LIST_ITEM;
else else
//o is: return AccessibleRole::LABEL; //o is: return AccessibleRole::LABEL;
return AccessibleRole::TREE_ITEM; return AccessibleRole::TREE_ITEM;
} }
return AccessibleRole::UNKNOWN;
} }
// ----------------------------------------------------------------------------- // -----------------------------------------------------------------------------
OUString SAL_CALL AccessibleListBoxEntry::getAccessibleDescription( ) throw (RuntimeException) OUString SAL_CALL AccessibleListBoxEntry::getAccessibleDescription( ) throw (RuntimeException)