summaryrefslogtreecommitdiffstats
path: root/src/cmd/mkinitramfs.sh
diff options
context:
space:
mode:
authorP. J. McDermott <pj@pehjota.net>2016-01-17 09:45:31 (EST)
committer P. J. McDermott <pj@pehjota.net>2016-01-17 09:45:31 (EST)
commit3a4fe66ffc3b19ef9b5f4bb6c80ba2c2219be866 (patch)
tree26b12c7d539b6e037e424662da713adcdb856ca9 /src/cmd/mkinitramfs.sh
parent1cc634639779b8cbb0dc6ce94f1663b3232c5673 (diff)
cmd/mkinitramfs: Use non-exiting error() and clean up on error
Diffstat (limited to 'src/cmd/mkinitramfs.sh')
-rw-r--r--src/cmd/mkinitramfs.sh3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/cmd/mkinitramfs.sh b/src/cmd/mkinitramfs.sh
index 0ff0923..df756ca 100644
--- a/src/cmd/mkinitramfs.sh
+++ b/src/cmd/mkinitramfs.sh
@@ -62,8 +62,9 @@ cmd_mkinitramfs_main()
plat="$(cat "${root}/etc/proteanos_plat")"
if ! img="$(profile_find_kernel "${root}" "${arch}" "${plat}")"; then
+ error "$(get_msg 'cmd_mkinitramfs_kernel_not_found')"
[ "x${dev}" != 'x' ] && block_umount "${root}"
- error 2 "$(get_msg 'cmd_mkinitramfs_kernel_not_found')"
+ return 2
fi
cp -p "${root}/${img}" "${linux_output}"