Fixed incorrect invalid index check

This commit is contained in:
Jordan Cristiano 2015-07-28 21:07:55 -04:00
parent 42955b7e01
commit 0f471d9b7a

View File

@ -75,7 +75,7 @@ inline const char* DemoCmdToString(unsigned int cmd)
"dem_stop",
"dem_stringtables"
};
if (cmd > (sizeof(cmdNames) / sizeof(const char*)))
if (cmd >= (sizeof(cmdNames) / sizeof(const char*)))
{
return "";
}