coverity#736162 Dereference null return value

Change-Id: If2a8f2ba79f3efa557cacb29553ba70e233f88f5
This commit is contained in:
Caolán McNamara
2014-03-28 10:24:16 +00:00
parent 2e82733434
commit 315eea1273

View File

@@ -3528,7 +3528,7 @@ void PopupMenu::SelectEntry( sal_uInt16 nId )
{
size_t nPos = 0;
MenuItemData* pData = GetItemList()->GetData( nId, nPos );
if ( pData->pSubMenu )
if (pData && pData->pSubMenu)
ImplGetFloatingWindow()->ChangeHighlightItem( nPos, true );
else
ImplGetFloatingWindow()->EndExecute( nId );