grub_script_lexer_yywrap: Update len synchronously with line.
This commit is contained in:
parent
59d4036594
commit
66ce4d1aef
2 changed files with 6 additions and 0 deletions
|
@ -1,3 +1,8 @@
|
|||
2015-01-20 Vladimir Serbinenko <phcoder@gmail.com>
|
||||
|
||||
* grub-core/script/lexer.c (grub_script_lexer_yywrap): Update len
|
||||
synchronously with line.
|
||||
|
||||
2015-01-20 Vladimir Serbinenko <phcoder@gmail.com>
|
||||
|
||||
Replace explicit sizeof divisions by ARRAY_SIZE.
|
||||
|
|
|
@ -164,6 +164,7 @@ grub_script_lexer_yywrap (struct grub_parser_param *parserstate,
|
|||
{
|
||||
grub_free (line);
|
||||
line = grub_strdup ("\n");
|
||||
len = 1;
|
||||
}
|
||||
else if (len && line[len - 1] != '\n')
|
||||
{
|
||||
|
|
Loading…
Reference in a new issue