Cleanup hid_joypad_name
This commit is contained in:
parent
a9e627ca57
commit
c1e343cec8
|
@ -86,7 +86,9 @@ static bool hid_joypad_rumble(unsigned pad,
|
|||
|
||||
static const char *hid_joypad_name(unsigned pad)
|
||||
{
|
||||
return generic_hid->name((void*)hid_driver_get_data(), pad);
|
||||
if (generic_hid && generic_hid->name)
|
||||
return generic_hid->name((void*)hid_driver_get_data(), pad);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
input_device_driver_t hid_joypad = {
|
||||
|
|
Loading…
Reference in New Issue