mirror of
https://github.com/RetroDECK/ES-DE.git
synced 2025-02-16 20:15:38 +00:00
The SDL error message is now printed to the log if a controller could not be added
This commit is contained in:
parent
573b0859e1
commit
5fcf2ea49a
|
@ -635,7 +635,8 @@ void InputManager::addControllerByDeviceIndex(Window* window, int deviceIndex)
|
||||||
SDL_GameController* controller {SDL_GameControllerOpen(deviceIndex)};
|
SDL_GameController* controller {SDL_GameControllerOpen(deviceIndex)};
|
||||||
|
|
||||||
if (controller == nullptr) {
|
if (controller == nullptr) {
|
||||||
LOG(LogError) << "Couldn't add controller with device index " << deviceIndex;
|
LOG(LogError) << "Couldn't add controller with device index " << deviceIndex << " ("
|
||||||
|
<< SDL_GetError() << ")";
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue