diff options
author | Richard Jones <rjones@redhat.com> | 2009-12-04 15:39:55 +0000 |
---|---|---|
committer | Richard Jones <rjones@redhat.com> | 2009-12-04 15:39:55 +0000 |
commit | 09e796a0f0257c6dde56a64312db891d450e1b9a (patch) | |
tree | 5fe76d32eca706b874c7d9e3b1f46b4a6b16edd5 | |
parent | f9a9bfcc134816f16a61890897dd7a39a14cb72d (diff) | |
download | febootstrap-09e796a0f0257c6dde56a64312db891d450e1b9a.tar.gz febootstrap-09e796a0f0257c6dde56a64312db891d450e1b9a.tar.xz febootstrap-09e796a0f0257c6dde56a64312db891d450e1b9a.zip |
supermin: Fix code which gets list of kernels.
(Same patch applied to libguestfs).
-rwxr-xr-x | febootstrap-supermin-helper.sh | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/febootstrap-supermin-helper.sh b/febootstrap-supermin-helper.sh index 0849b1f..f6a54e6 100755 --- a/febootstrap-supermin-helper.sh +++ b/febootstrap-supermin-helper.sh @@ -81,7 +81,10 @@ rm -f "$kernel" "$initrd" # without arch second. arch=$(echo "@host_cpu@" | sed 's/^i.86$/i?86/') -kernels=$(ls -1dvr /boot/vmlinuz-*.$arch* 2>/dev/null | grep -v xen; ls -1dvr /boot/vmlinuz-* 2>/dev/null | grep -v xen) +kernels=$( + ls -1dvr /boot/vmlinuz-*.$arch* 2>/dev/null | grep -v xen ||: ; + ls -1dvr /boot/vmlinuz-* 2>/dev/null | grep -v xen +) if [ -z "$kernels" ]; then echo "$0: failed to find a suitable kernel in /boot directory" >&2 |