[PATCH 0/2] discover/grub2: A couple of fixes for default entry matching

Javier Martinez Canillas javierm at redhat.com
Fri Jun 21 02:09:54 AEST 2019


Hello,

I have found a couple of bugs in Petitboot when setting a default entry.
This patch-set fixes these issues.

Patch #1 allows to define the default entry using its title regardless if
that entry has an id defined or not.

Patch #2 allows to not only define the menuentry id as --id=foo, but also
as --id foo which should be supported as well according to the GRUB docs.

Best regards,
Javier


Javier Martinez Canillas (2):
  discover/grub2: Allow using title for default even if id was defined
  discover/grub2: Allow to separate the --id argument using a space char

 discover/grub2/script.c                    | 21 ++++++++-----
 test/parser/Makefile.am                    |  2 ++
 test/parser/test-grub2-default-id-space.c  | 34 ++++++++++++++++++++++
 test/parser/test-grub2-default-id.c        | 34 ++++++++++++++++++++++
 test/parser/test-grub2-default-multiword.c |  4 +--
 5 files changed, 85 insertions(+), 10 deletions(-)
 create mode 100644 test/parser/test-grub2-default-id-space.c
 create mode 100644 test/parser/test-grub2-default-id.c

-- 
2.21.0



More information about the Petitboot mailing list