grubby-bls: use id instead of title to get the default entry
The wrapper is using the title before to store the default entry, but we are now using the entry id for grub2, so make the wrapper query the id. Resolves: rhbz#1638103 Signed-off-by: Javier Martinez Canillas <javierm@redhat.com>
This commit is contained in:
parent
7d53b5e0a6
commit
db3ffac800
@ -127,13 +127,13 @@ get_default_index() {
|
||||
|
||||
# GRUB2 and zipl use different fields to set the default entry
|
||||
if [[ $bootloader = "grub2" ]]; then
|
||||
title="$default"
|
||||
id="$default"
|
||||
else
|
||||
version="$default"
|
||||
fi
|
||||
|
||||
for i in ${!bls_file[@]}; do
|
||||
if [[ $title = ${bls_title[$i]} || $version = ${bls_version[$i]} ||
|
||||
if [[ $title = ${bls_title[$i]} || $id = ${bls_id[$i]} ||
|
||||
$i -eq $index ]]; then
|
||||
echo $i
|
||||
return
|
||||
|
Loading…
Reference in New Issue
Block a user