diff options
author | Zac Medico <zmedico@gentoo.org> | 2008-06-28 21:58:02 +0000 |
---|---|---|
committer | Zac Medico <zmedico@gentoo.org> | 2008-06-28 21:58:02 +0000 |
commit | 18a98e25f811200020d375146c06167bc8937231 (patch) | |
tree | b62546197bf7ad15eeab1d5a5204e40c8a01c4b9 | |
parent | eb3e73c9ade89a7f9d59664c4869fa8a278b095e (diff) | |
download | portage-18a98e25f811200020d375146c06167bc8937231.tar.gz portage-18a98e25f811200020d375146c06167bc8937231.tar.bz2 portage-18a98e25f811200020d375146c06167bc8937231.zip |
Copy portageq exit code validation from has_version() to best_version().
svn path=/main/trunk/; revision=10836
-rwxr-xr-x | bin/ebuild.sh | 12 |
1 files changed, 12 insertions, 0 deletions
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() { |