From: Zac Medico Date: Sat, 28 Jun 2008 21:58:02 +0000 (-0000) Subject: Copy portageq exit code validation from has_version() to best_version(). X-Git-Tag: v2.2_rc2~289 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=18a98e25f811200020d375146c06167bc8937231;p=portage.git Copy portageq exit code validation from has_version() to best_version(). svn path=/main/trunk/; revision=10836 --- diff --git a/bin/ebuild.sh b/bin/ebuild.sh index 2bb6e60ee..4e35f7c4d 100755 --- a/bin/ebuild.sh +++ b/bin/ebuild.sh @@ -204,6 +204,18 @@ best_version() { # Takes single depend-type atoms. PYTHONPATH="${PORTAGE_PYM_PATH}:${PYTHONPATH}" \ "${PORTAGE_BIN_PATH}/portageq" 'best_version' "${ROOT}" "$1" + local retval=$? + case "${retval}" in + 0) + return 0 + ;; + 1) + return 1 + ;; + *) + die "unexpected portageq exit code: ${retval}" + ;; + esac } use_with() {