Fix dracut code to be POSIX compliant

The redirect type "< <(...)" is not POSIX complians and leads
to a syntax error in dracut which calls bash as "sh" leading
it to be restricted to POSIX only
This commit is contained in:
Marcus Schäfer 2025-07-18 10:35:32 +02:00
parent 6ecd63948d
commit e911bd6861
No known key found for this signature in database
GPG Key ID: A16C1128698C8CAC

View File

@ -54,8 +54,8 @@ function sort_disk_entries {
fi
count=$((count + 1))
done
readarray -td '' list_items_sorted \
< <(printf '%s\0' "${device_array[@]}" | sort -z)
printf '%s\0' "${device_array[@]}" | sort -z > list_items_sorted.txt
readarray -td '' list_items_sorted < list_items_sorted.txt
echo "${list_items_sorted[*]}"
}