backport the locs reading fix

This commit is contained in:
Bill Currie 2001-11-27 21:25:54 +00:00
parent 86f6ce2265
commit 6be99353a1
1 changed files with 3 additions and 1 deletions

View File

@ -141,8 +141,10 @@ locs_load (char *filename)
t2[0] = '\0';
// handle dos format lines (COM_FOpenFile is binary only)
// and unix is effectively binary only anyway
if (t2 > t1 && t2[-1] == '\r')
while (t2 > t1 && t2[-1] == '\r') {
t2[-1] = '\0';
t2--;
}
}
locs_add (loc, t1);
}