builder: fix small regression in subkey parsing

Introduced in 5cbdf35d65, it caused the
first character of the value to be skipped if the key has a subkey.
This commit is contained in:
Pino Toscano
2014-01-22 15:34:22 +01:00
parent 13bca32e4e
commit 9e4357ca54

View File

@@ -65,7 +65,7 @@ extern void yyerror (const char *);
if (yytext[i] == '[') {
size_t j = strcspn (yytext+i+1, "]");
yylval.field->subkey = strndup (yytext+i+1, j);
i += 1+j+2;
i += 1+j+1;
} else {
yylval.field->subkey = NULL;
}