mdev: do not treat non-leading '#' chars as start of comment. Closes 4676

Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
This commit is contained in:
Denys Vlasenko
2012-01-11 00:37:17 +01:00
parent 982fdaf4b2
commit 499597d6ef
3 changed files with 6 additions and 4 deletions

View File

@ -206,7 +206,8 @@ static void parse_next_rule(void)
char *tokens[4];
char *val;
if (!config_read(G.parser, tokens, 4, 3, "# \t", PARSE_NORMAL))
/* No PARSE_EOL_COMMENTS, because command may contain '#' chars */
if (!config_read(G.parser, tokens, 4, 3, "# \t", PARSE_NORMAL & ~PARSE_EOL_COMMENTS))
break;
/* Fields: [-]regex uid:gid mode [alias] [cmd] */