Skip to content

Commit

Permalink
Fix a bug when hitting GPT partitions with no (known) filesystem and/…
Browse files Browse the repository at this point in the history
…or UUID
  • Loading branch information
Christian Schmidt committed Nov 5, 2022
1 parent 6c96145 commit 56b1c76
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions buildkernel
Original file line number Diff line number Diff line change
Expand Up @@ -389,7 +389,7 @@ partuuid_is_on_usb_device() {
return 1
}
check_partuuid_exists() {
if [ -z "${ALLUUIDS[${1}]}" ]; then
if [ -z "${ALLUUIDS[${1}]+test}" ]; then
die "Partition with UUID '${1}' does not exist"
fi
}
Expand Down Expand Up @@ -577,7 +577,7 @@ load_all_devices() {
shopt -s lastpipe
lsblk -nlp -o NAME,FSTYPE,UUID,PARTUUID -E UUID |
while read NEXTDEV NEXTFSTYPE NEXTUUID NEXTPARTUUID; do
if [ -n "${NEXTFSTYPE}" ]; then
if [ -n "${NEXTFSTYPE}" -a -n "${NEXTUUID}" ]; then
ALLUUIDS[${NEXTUUID}]="${NEXTDEV}"
FSUUIDS[${NEXTUUID}]="1"
if [ -n "${NEXTPARTUUID}" ]; then
Expand Down

0 comments on commit 56b1c76

Please sign in to comment.