V_LevelNameHeight: Don't use strlen for possibly every iteration depending on optimisation level

This commit is contained in:
toaster 2023-07-11 18:54:42 +01:00
parent 9e4e996a5e
commit e3ee8f9afa

View file

@ -2987,7 +2987,7 @@ INT32 V_LevelNameHeight(const char *string)
INT32 c, w = 0;
size_t i;
for (i = 0; i < strlen(string); i++)
for (i = 0; string[i]; i++)
{
c = string[i] - LT_FONTSTART;
if (c < 0 || c >= LT_FONTSIZE || !fontv[LT_FONT].font[c])