Kaydet (Commit) 221a3413 authored tarafından Caolán McNamara's avatar Caolán McNamara

coverity#1397056 Dereference null return value

Change-Id: Ieda3afdbdbcc8aa21f6584edc21738c4edb84000
üst 3249009b
......@@ -1844,12 +1844,15 @@ void SvTreeListBox::SetCheckButtonState( SvTreeListEntry* pEntry, SvButtonState
void SvTreeListBox::SetCheckButtonInvisible( SvTreeListEntry* pEntry)
{
if( nTreeFlags & SvTreeFlags::CHKBTN )
{
SvLBoxButton* pItem = static_cast<SvLBoxButton*>(pEntry->GetFirstItem(SvLBoxItemType::Button));
pItem->SetStateInvisible();
InvalidateEntry( pEntry );
}
SvLBoxButton* pItem = (nTreeFlags & SvTreeFlags::CHKBTN) ?
static_cast<SvLBoxButton*>(pEntry->GetFirstItem(SvLBoxItemType::Button)) :
nullptr;
if (!pItem)
return;
pItem->SetStateInvisible();
InvalidateEntry(pEntry);
}
SvButtonState SvTreeListBox::GetCheckButtonState( SvTreeListEntry* pEntry ) const
......
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