minor simplification

git-svn-id: svn://svn.code.sf.net/p/quakespasm/code/trunk/quakespasm@1629 af15c1b1-3010-417e-b628-4374ebc0bcbd
This commit is contained in:
Ozkan Sezer 2019-09-12 12:33:02 +00:00
parent e041b958c7
commit 0a6a5c62c8
3 changed files with 3 additions and 3 deletions

View file

@ -208,7 +208,7 @@ void Fog_ParseWorldspawn (void)
q_strlcpy(key, com_token + 1, sizeof(key));
else
q_strlcpy(key, com_token, sizeof(key));
while (strlen(key) > 0 && key[strlen(key)-1] == ' ') // remove trailing spaces
while (key[0] && key[strlen(key)-1] == ' ') // remove trailing spaces
key[strlen(key)-1] = 0;
data = COM_Parse(data);
if (!data)

View file

@ -355,7 +355,7 @@ static void R_ParseWorldspawn (void)
q_strlcpy(key, com_token + 1, sizeof(key));
else
q_strlcpy(key, com_token, sizeof(key));
while (strlen(key) > 0 && key[strlen(key)-1] == ' ') // remove trailing spaces
while (key[0] && key[strlen(key)-1] == ' ') // remove trailing spaces
key[strlen(key)-1] = 0;
data = COM_Parse(data);
if (!data)

View file

@ -251,7 +251,7 @@ void Sky_NewMap (void)
q_strlcpy(key, com_token + 1, sizeof(key));
else
q_strlcpy(key, com_token, sizeof(key));
while (strlen(key) > 0 && key[strlen(key)-1] == ' ') // remove trailing spaces
while (key[0] && key[strlen(key)-1] == ' ') // remove trailing spaces
key[strlen(key)-1] = 0;
data = COM_Parse(data);
if (!data)