mirror of
https://github.com/yawut/SDL.git
synced 2026-09-30 12:16:43 -05:00
SDL_JoystickInit: If malloc() fails, pretend no joysticks were detected.
This commit is contained in:
@@ -63,8 +63,8 @@ int SDL_JoystickInit(void)
|
||||
SDL_numjoysticks = 0;
|
||||
} else {
|
||||
memset(SDL_joysticks, 0, arraylen);
|
||||
SDL_numjoysticks = status;
|
||||
}
|
||||
SDL_numjoysticks = status;
|
||||
status = 0;
|
||||
}
|
||||
default_joystick = NULL;
|
||||
|
||||
Reference in New Issue
Block a user