[4/7] grub2/grub2-parser: accept no whitespace in grub menuentry
diff mbox series

Message ID 1518055632-11462-5-git-send-email-brett.grandbois@opengear.com
State Accepted
Headers show
Series
  • Resubmit: Yocto and musl libc fixes, syslinux parser support
Related show

Commit Message

Grandbois, Brett Feb. 8, 2018, 2:07 a.m. UTC
The Yocto wic grub support will generate a grub.cfg with no whitespace
between the ending quote of the menuentry label and the opening bracket.
There doesn't seem to be anything in the specification that this is
illegal so accept it here.

Signed-off-by: Brett Grandbois <brett.grandbois@opengear.com>
---
 discover/grub2/grub2-parser.y | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Patch
diff mbox series

diff --git a/discover/grub2/grub2-parser.y b/discover/grub2/grub2-parser.y
index 598f0fe..527a61c 100644
--- a/discover/grub2/grub2-parser.y
+++ b/discover/grub2/grub2-parser.y
@@ -122,7 +122,7 @@  statement: {
 	| "function" word delim '{' statements '}' {
 		$$ = create_statement_function(parser, $2, $5);
 	}
-	| "menuentry" words delim
+	| "menuentry" words delim0
 		'{' statements '}' {
 		$$ = create_statement_menuentry(parser, $2, $5);
 	}