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

(cherry picked from commit 627e15871a)
This commit is contained in:
Sam Lantinga committed 2024-03-03 11:56:53 -08:00
1 parent c1149f88b6
commit a2f39399a1
1 file changed
+4 -3
+4 -3
View File
@@ -3280,10 +3280,11 @@ const char *SDL_GameControllerGetAppleSFSymbolsNameForAxis(SDL_GameController *g
} }
SDL_UnlockJoysticks(); SDL_UnlockJoysticks();
return retval; if (retval && *retval) {
#else return retval;
return NULL; }
#endif #endif
return NULL;
} }
/* vi: set ts=4 sw=4 expandtab: */ /* vi: set ts=4 sw=4 expandtab: */