fix a possible oob condition

This commit is contained in:
Bill Currie 2001-01-08 07:31:40 +00:00
parent b66c22d0e5
commit 3727753fde

View file

@ -179,7 +179,7 @@ COM_FileBase (char *in, char *out)
while (s != in && *s != '.')
s--;
for (s2 = s; *s2 && *s2 != '/'; s2--);
for (s2 = s; s2 != in && *s2 && *s2 != '/'; s2--);
if (s - s2 < 2)
strcpy (out, "?model?");