Redid COM_StripExtension to only strip from the first dot after the last slash in a filename.

git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@1158 fc73d0e0-1445-4013-8a0c-d673dee63da5
This commit is contained in:
Mark Olsen 2005-07-25 13:23:42 +00:00
parent e9b8f7899f
commit b5d6325fe3
1 changed files with 13 additions and 3 deletions

View File

@ -1380,9 +1380,19 @@ COM_StripExtension
*/
void COM_StripExtension (char *in, char *out)
{
while (*in && *in != '.')
*out++ = *in++;
*out = 0;
char *s;
strcpy(out, in);
s = out+strlen(out);
while(*s != '/' && s != out)
{
if (*s == '.')
*s = 0;
s--;
}
}
/*