mirror of
https://github.com/libsdl-org/SDL.git
synced 2025-10-05 09:26:25 +00:00
SDL_GetHaptics() follows the SDL_GetStringRule
This commit is contained in:
@@ -63,7 +63,7 @@ static SDL_bool SDL_GetHapticIndex(SDL_HapticID instance_id, int *driver_index)
|
||||
return SDL_FALSE;
|
||||
}
|
||||
|
||||
SDL_HapticID *SDL_GetHaptics(int *count)
|
||||
const SDL_HapticID *SDL_GetHaptics(int *count)
|
||||
{
|
||||
int device_index;
|
||||
int haptic_index = 0, num_haptics = 0;
|
||||
@@ -89,7 +89,7 @@ SDL_HapticID *SDL_GetHaptics(int *count)
|
||||
}
|
||||
}
|
||||
|
||||
return haptics;
|
||||
return SDL_FreeLater(haptics);
|
||||
}
|
||||
|
||||
const char *SDL_GetHapticNameForID(SDL_HapticID instance_id)
|
||||
|
Reference in New Issue
Block a user