Fix: Dereference of null pointer in FMenu

This commit is contained in:
Markus Gans 2016-08-06 22:46:37 +02:00
parent 4deede746f
commit 485b8e25aa
1 changed files with 9 additions and 3 deletions

View File

@ -612,11 +612,17 @@ void FMenu::draw()
if ( (flags & fc::shadow) != 0 ) if ( (flags & fc::shadow) != 0 )
{ {
term_area* area = 0;
FWindow* area_widget = getWindowWidget(this);
drawMenuShadow(); drawMenuShadow();
term_area* area = getWindowWidget(this)->getVWin();
if ( area ) if ( area_widget )
putArea (xpos+xmin-1, ypos+ymin-1, area); {
area = area_widget->getVWin();
if ( area )
putArea (xpos+xmin-1, ypos+ymin-1, area);
}
} }
else else
updateVTerm(true); updateVTerm(true);