summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorpeter <peter@FreeBSD.org>1999-07-01 16:20:16 +0000
committerpeter <peter@FreeBSD.org>1999-07-01 16:20:16 +0000
commit140b47277bef322c164be5984d1b3c77e3162a14 (patch)
treeb85a27989af06d6cf8d4bd73569d022acdf8fc08
parent8a33200f02747ae1522a1f6a6dfc3ce977e60232 (diff)
downloadFreeBSD-src-140b47277bef322c164be5984d1b3c77e3162a14.zip
FreeBSD-src-140b47277bef322c164be5984d1b3c77e3162a14.tar.gz
Don't include trailing whitespace in ID tokens before comments. ie:
options FOO=10 # comment would give FOO the value of "10 " and that caused unwanted touches on the opt_*.h files. I hope I've got this right..
-rw-r--r--usr.sbin/config/lang.l3
1 files changed, 2 insertions, 1 deletions
diff --git a/usr.sbin/config/lang.l b/usr.sbin/config/lang.l
index 4368695..b8ae325 100644
--- a/usr.sbin/config/lang.l
+++ b/usr.sbin/config/lang.l
@@ -78,6 +78,7 @@ struct kt {
{ "minor", MINOR },
{ "net", NET }, /* XXX going away */
{ "nexus", NEXUS },
+ { "option", OPTIONS },
{ "options", OPTIONS },
{ "port", PORT },
{ "priority", PRIORITY },
@@ -149,7 +150,7 @@ ID [A-Za-z_][-A-Za-z_0-9]*
tprintf("id(%s) ", yytext+1);
return ID;
}
-<TOEOL>[^#\n]* {
+<TOEOL>[^# \t\n]* {
BEGIN 0;
yylval.str = strdup(yytext);
tprintf("id(%s) ", yytext);
OpenPOWER on IntegriCloud