From 1b88017fc5d7d9939e9d11ba1a9eee950f3d3f6b Mon Sep 17 00:00:00 2001 From: heinrich5991 Date: Thu, 13 Apr 2017 00:19:19 +0200 Subject: [PATCH] Fix crashbug in bind system Restore old behavior around the bind's Get() function, return "" if there is no bind. Fixes #730. --- src/game/client/components/binds.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/game/client/components/binds.cpp b/src/game/client/components/binds.cpp index 5e346b6da..d92426495 100644 --- a/src/game/client/components/binds.cpp +++ b/src/game/client/components/binds.cpp @@ -88,7 +88,7 @@ void CBinds::UnbindAll() const char *CBinds::Get(int KeyID) { - if(KeyID > 0 && KeyID < KEY_LAST) + if(KeyID > 0 && KeyID < KEY_LAST && m_apKeyBindings[KeyID]) return m_apKeyBindings[KeyID]; return ""; }