net: Use SDLNet_Linked_Version() to obtain runtime SDL_net version
This is a function, not a preprocessor macro, so its existence can't be checked using #ifdef. Furthermore, I can't think of a valid reason for the SDL devs to arbitrary drop it in a future release without warning, so we can safely assume it's always present for now. (Also, it's 'SDLNet', not 'Net'.)
This commit is contained in:
parent
dda3e04f9f
commit
6f69df12d1
1 changed files with 1 additions and 3 deletions
|
@ -1217,13 +1217,11 @@ std::string describe_versions()
|
|||
<< static_cast<int> (compile_version.patch) << " \n";
|
||||
#endif
|
||||
|
||||
#ifdef Net_Linked_Version
|
||||
const SDL_version *link_version=Net_Linked_Version();
|
||||
const SDL_version *link_version = SDLNet_Linked_Version();
|
||||
ss << "Running with SDL_net version: "
|
||||
<< static_cast<int> (link_version->major) << "."
|
||||
<< static_cast<int> (link_version->minor) << "."
|
||||
<< static_cast<int> (link_version->patch) << " .\n";
|
||||
#endif
|
||||
|
||||
return ss.str();
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue