coverity#1397204 Dereference null return value

Change-Id: Ief4b455b316b55ebf012a8650c96da037df0135c
This commit is contained in:
Caolán McNamara 2016-12-15 21:17:58 +00:00
parent eb0e2dabde
commit f74cad4568

View File

@ -222,7 +222,7 @@ static void lcl_SetCheckButton( SvTreeListEntry* pEntry, bool bCheck )
SvLBoxButton* pItem = static_cast<SvLBoxButton*>(pEntry->GetFirstItem(SvLBoxItemType::Button));
DBG_ASSERT(pItem,"SetCheckButton:Item not found");
if (pItem->GetType() == SvLBoxItemType::Button)
if (pItem && pItem->GetType() == SvLBoxItemType::Button)
{
if (bCheck)
pItem->SetStateChecked();