diff options
author | RĂ©mi Verschelde <remi@verschelde.fr> | 2016-08-28 17:48:19 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2016-08-28 17:48:19 +0200 |
commit | 1b80edafcaeca5c9f61c86448a16238fd82bb6da (patch) | |
tree | d7c7ce20f313d0c50a19e3bef0f042d7925dbbda /main/input_default.cpp | |
parent | 6c674375e52e8228e2aec53ceb0ac3d3f4a0f4d9 (diff) | |
parent | 02a8604906b1f50000f96e2f8dbd0d50a162ab6f (diff) |
Merge pull request #6312 from Hinsbart/guid_fix
Fix crash when trying to access the guid of an unavailable Gamepad.
Diffstat (limited to 'main/input_default.cpp')
-rw-r--r-- | main/input_default.cpp | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/main/input_default.cpp b/main/input_default.cpp index c655b409ff..f93a142c54 100644 --- a/main/input_default.cpp +++ b/main/input_default.cpp @@ -1055,6 +1055,7 @@ bool InputDefault::is_joy_mapped(int p_device) { } String InputDefault::get_joy_guid_remapped(int p_device) const { + ERR_FAIL_COND_V(!joy_names.has(p_device), ""); return joy_names[p_device].uid; } |