From: Zbigniew Jędrzejewski-Szmek Date: Sat, 2 Jul 2022 12:45:07 +0000 (+0200) Subject: kernel-install: use set -e X-Git-Tag: v252-rc1~671^2~1 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=b9b55a884bcc111c5f9bab3df958b6bd71ee25e5;p=thirdparty%2Fsystemd.git kernel-install: use set -e This means that we'll fail hard if something goes wrong, e.g. reading of a config file. I think this is appropriate. If errors should be ignored, the caller should do that on their end. --- diff --git a/src/kernel-install/50-depmod.install b/src/kernel-install/50-depmod.install index b43333762bc..d4b991cfd62 100755 --- a/src/kernel-install/50-depmod.install +++ b/src/kernel-install/50-depmod.install @@ -18,6 +18,8 @@ # You should have received a copy of the GNU Lesser General Public License # along with systemd; If not, see . +set -e + COMMAND="${1:?}" KERNEL_VERSION="${2:?}" diff --git a/src/kernel-install/90-loaderentry.install b/src/kernel-install/90-loaderentry.install index 96e24194c40..b34bbd83cdf 100755 --- a/src/kernel-install/90-loaderentry.install +++ b/src/kernel-install/90-loaderentry.install @@ -18,6 +18,8 @@ # You should have received a copy of the GNU Lesser General Public License # along with systemd; If not, see . +set -e + COMMAND="${1:?}" KERNEL_VERSION="${2:?}" ENTRY_DIR_ABS="${3:?}" diff --git a/src/kernel-install/kernel-install.in b/src/kernel-install/kernel-install.in index 30b28f4658b..a597e411336 100755 --- a/src/kernel-install/kernel-install.in +++ b/src/kernel-install/kernel-install.in @@ -20,6 +20,8 @@ skip_remaining=77 +set -e + usage() { echo "Usage:"