Return the first device if grub-probe returns all devices of a ZFS pool
for instance.  Closes: #1139182
---
 grub-installer | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/grub-installer b/grub-installer
index 30e7ecfc..ee0b2c56 100755
--- a/grub-installer
+++ b/grub-installer
@@ -151,7 +151,7 @@
 }

 findfs () {
-       if ! grub_probe -t device $1; then
+       if ! grub_probe -t device $1 | head -n1; then
                mount | grep "on $ROOT${1%/} " | tail -n1 | cut -d' ' -f1
        fi
 }
--
2.47.3

Reply via email to