mirror of
https://git.FreeBSD.org/src.git
synced 2024-12-19 10:53:58 +00:00
Don't ignore unknown characters. The previous code treated a line like:
hosts:!!!!!!!!@@@@@$%^&*()()*$(files{}{}|||++!)(dns exactly the same as: hosts: files dns Recover from parse errors by looking for the end of a line; this allows entries without errors to still be parsed even if there is an erroneous entry earlier in the file.
This commit is contained in:
parent
33b6e7aabe
commit
70982dca88
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=86162
@ -94,9 +94,7 @@ STRING [a-zA-Z][a-zA-Z0-9_]*
|
||||
return STRING;
|
||||
}
|
||||
|
||||
[:=\[\]] return yytext[0];
|
||||
|
||||
. ; /* ignore all else */
|
||||
. return yytext[0];
|
||||
|
||||
%%
|
||||
|
||||
|
@ -87,6 +87,10 @@ Entry
|
||||
{
|
||||
_nsdbtput(&curdbt);
|
||||
}
|
||||
| error NL
|
||||
{
|
||||
yyerrok;
|
||||
}
|
||||
;
|
||||
|
||||
Database
|
||||
|
Loading…
Reference in New Issue
Block a user