SDL_GetGamepadAppleSFSymbolsNameForAxis() returns NULL if the symbol isn't found

This commit is contained in:
Sam Lantinga
2024-03-03 11:55:40 -08:00
parent 5f37242607
commit 1b86a1c684

View File

@@ -3771,8 +3771,9 @@ const char *SDL_GetGamepadAppleSFSymbolsNameForAxis(SDL_Gamepad *gamepad, SDL_Ga
}
SDL_UnlockJoysticks();
return retval;
#else
return NULL;
if (retval && *retval) {
return retval;
}
#endif
return NULL;
}