fix: Do not use NULL in arithmetic
Signed-off-by: Vyacheslav Ivanov <islavaivanov76@gmail.com>
This commit is contained in:
parent
2cd6837da9
commit
7c8f04aa75
@ -115,8 +115,8 @@ std::string input_util::to_string(keycode code) {
|
|||||||
char name[64];
|
char name[64];
|
||||||
int result =
|
int result =
|
||||||
GetKeyNameTextA(glfwGetKeyScancode(icode_repr) << 16, name, 64);
|
GetKeyNameTextA(glfwGetKeyScancode(icode_repr) << 16, name, 64);
|
||||||
if (result == NULL) return "Unknown";
|
if (result == 0) return "Unknown";
|
||||||
return std::string(name);
|
return name;
|
||||||
#else
|
#else
|
||||||
const char* name =
|
const char* name =
|
||||||
glfwGetKeyName(icode_repr, glfwGetKeyScancode(icode_repr));
|
glfwGetKeyName(icode_repr, glfwGetKeyScancode(icode_repr));
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user