fix a buffer underflow

This commit is contained in:
Bill Currie 2003-05-15 05:10:28 +00:00
parent dd0332632e
commit 5fac3e6f3a
1 changed files with 1 additions and 1 deletions

View File

@ -573,7 +573,7 @@ separate_compile (void)
f = output_file->str + strlen (output_file->str);
while (f >= output_file->str && *f != '.' && *f != '/')
f--;
if (*f == '.') {
if (f >= output_file->str && *f == '.') {
output_file->size -= strlen (f);
dstring_appendstr (extension, f);
*f = 0;