(xuflds): Terminated the value list when a bad separator is found.

This commit is contained in:
Ron Koenderink 2006-01-22 17:37:05 +00:00
parent 58bc018b53
commit 8900dfaa3d

View file

@ -221,8 +221,10 @@ xuflds(FILE *fp, struct value values[])
ch = getc(fp);
if (ch == '\n')
ungetc(ch, fp);
else if (ch != ' ' && ch != '\t')
else if (ch != ' ' && ch != '\t') {
values[i].v_type = VAL_NOTUSED;
return gripe("Bad field separator after field %d", i + 1);
}
}
}