macOS: fix crash if and when joystick-init-on-add fails

This commit is contained in:
David Ludwig 2020-02-05 13:16:17 -05:00
parent a199cb89ad
commit d88f3f5226
1 changed files with 1 additions and 1 deletions

View File

@ -137,7 +137,7 @@ FreeDevice(recDevice *removeDevice)
if ( gpDeviceList == removeDevice ) {
gpDeviceList = pDeviceNext;
} else {
} else if (gpDeviceList) {
recDevice *device = gpDeviceList;
while (device->pNext != removeDevice) {
device = device->pNext;