From 1cc634639779b8cbb0dc6ce94f1663b3232c5673 Mon Sep 17 00:00:00 2001 From: P. J. McDermott Date: Sun, 17 Jan 2016 09:44:08 -0500 Subject: cmd/build: Use non-exiting error() and clean up on error --- (limited to 'src') diff --git a/src/cmd/build.sh b/src/cmd/build.sh index dbfd910..86d770c 100644 --- a/src/cmd/build.sh +++ b/src/cmd/build.sh @@ -73,8 +73,9 @@ cmd_build_main() profile_detect "${root}" if ! [ -d "${cmd_build_pkg_dir}" ]; then - error 2 "$(get_msg 'cmd_build_not_a_dir')" \ - "${cmd_build_pkg_dir}" + error "$(get_msg 'cmd_build_not_a_dir')" "${cmd_build_pkg_dir}" + [ "x${dev}" != 'x' ] && block_umount "${root}" + return 2 fi package_init "${cmd_build_pkg_dir}" package_set_substvars "${arch}" "${plat}" -- cgit v0.9.1