parse empty lines

Signed-off-by: Michel-FK <michel.stempin@funkey-project.com>
This commit is contained in:
Michel-FK 2021-04-19 22:50:33 +02:00
parent 54d1051d3f
commit e74f6883cc

View File

@ -205,7 +205,7 @@ bool parse_config_line(char *line, mapping_list_t *list,
mapping_t *existing_mapping, new_mapping;
buffer[0] = '\0';
token = strtok_r(line, " \t", &next_token);
token = strtok_r(line, " \t\n", &next_token);
while (token != NULL) {
switch (state) {
case STATE_INIT:
@ -458,6 +458,7 @@ bool parse_config_line(char *line, mapping_list_t *list,
dump_mapping_list(list);
break;
case STATE_INIT:
case STATE_MAP:
break;