mirror of
https://github.com/Ryujinx/SDL.git
synced 2025-03-24 04:35:03 +00:00
Added a hint to return the version in the old format
Workaround for https://github.com/libsdl-org/SDL/issues/6177 for games that can't be updated.
This commit is contained in:
parent
b7fddb4c0e
commit
4e375996d3
10
src/SDL.c
10
src/SDL.c
|
@ -514,7 +514,17 @@ SDL_Quit(void)
|
||||||
void
|
void
|
||||||
SDL_GetVersion(SDL_version * ver)
|
SDL_GetVersion(SDL_version * ver)
|
||||||
{
|
{
|
||||||
|
if (!ver) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
SDL_VERSION(ver);
|
SDL_VERSION(ver);
|
||||||
|
|
||||||
|
if (SDL_GetHintBoolean("SDL_LEGACY_VERSION", SDL_FALSE)) {
|
||||||
|
/* Prior to SDL 2.24.0, the patch version was incremented with every release */
|
||||||
|
ver->patch = ver->minor;
|
||||||
|
ver->minor = 0;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Get the library source revision */
|
/* Get the library source revision */
|
||||||
|
|
Loading…
Reference in a new issue