From bcc9cf61ac92ddc6325e6b3637619a16664dfa05 Mon Sep 17 00:00:00 2001 From: "Tom G. Christensen" Date: Mon, 18 Aug 2008 17:33:06 +0000 Subject: [PATCH] Because of the nesting of the function calls a call to error inside the stack will not give me the exit I want. This should catch any errors and cause an exit in the appropriate place. --- buildpkg.functions | 2 ++ 1 file changed, 2 insertions(+) diff --git a/buildpkg.functions b/buildpkg.functions index abd608a..cecb301 100644 --- a/buildpkg.functions +++ b/buildpkg.functions @@ -376,6 +376,8 @@ unpack() # Note observe order here, since get_source_absfilename can exit with $E_BAD_FILE this # provides context for resolving! absfile="$(get_source_absfilename $snum)" + # Catch any badness from the get_source function stack + [ "$?" != "0" ] && error $E_BAD_FILE unpack # Determine filetype and unpack case $suffix in 'tar') ${__tar} -xf $absfile;;