introduce and use __cdist_exec_fail_on_error

Signed-off-by: Nico Schottelius <nico@kr.ethz.ch>
This commit is contained in:
Nico Schottelius 2011-02-22 11:39:23 +01:00
commit 5dcb719844
3 changed files with 5 additions and 29 deletions

View file

@ -181,7 +181,8 @@ __cdist_object_source()
__cdist_exec_fail_on_error()
{
sh -e "$1"
sh -e "$@"
[ "$?" -eq 0 ] || __cdist_exit_err "Error: $1 exited non-zero."
}