mirror of
https://github.com/holub/mame
synced 2025-04-20 15:32:45 +03:00
ui/selgame.cpp: Avoid assert in std::vector when no items in menu. (#9978)
This commit is contained in:
parent
db6590cb11
commit
a8b6bdfcac
@ -164,7 +164,7 @@ void menu_select_game::menu_activated()
|
||||
|
||||
void menu_select_game::handle(event const *ev)
|
||||
{
|
||||
if (!m_prev_selected)
|
||||
if (!m_prev_selected && item_count() > 0)
|
||||
m_prev_selected = item(0).ref();
|
||||
|
||||
// if I have to select software, force software list submenu
|
||||
|
Loading…
Reference in New Issue
Block a user