forked from len0rd/rockbox
plugins: playing time: fix possible crash on sys event
Change-Id: I7b3580c56e2b285f56b9e2195fbf3c14b6cd96e5
This commit is contained in:
parent
76ec55cc49
commit
e122243bb0
1 changed files with 6 additions and 1 deletions
|
@ -351,8 +351,13 @@ static bool playing_time(void)
|
||||||
if (rb->list_do_action(CONTEXT_LIST, HZ/2, &pt_lists, &key) == 0
|
if (rb->list_do_action(CONTEXT_LIST, HZ/2, &pt_lists, &key) == 0
|
||||||
&& key!=ACTION_NONE && key!=ACTION_UNKNOWN)
|
&& key!=ACTION_NONE && key!=ACTION_UNKNOWN)
|
||||||
{
|
{
|
||||||
|
bool usb = rb->default_event_handler(key) == SYS_USB_CONNECTED;
|
||||||
|
|
||||||
|
if (!usb && IS_SYSEVENT(key))
|
||||||
|
continue;
|
||||||
|
|
||||||
rb->talk_force_shutup();
|
rb->talk_force_shutup();
|
||||||
return(rb->default_event_handler(key) == SYS_USB_CONNECTED);
|
return usb;
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue