summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorZac Medico <zmedico@gentoo.org>2006-09-23 09:47:16 +0000
committerZac Medico <zmedico@gentoo.org>2006-09-23 09:47:16 +0000
commitce313966c95b66a64e3c1d2287eeceb34b0dca84 (patch)
treef6fbf9496035501507d738753c4187de76a4ec38
parent77864bbb62d75ae9581c51761e6b7fe90790727b (diff)
downloadportage-ce313966c95b66a64e3c1d2287eeceb34b0dca84.tar.gz
portage-ce313966c95b66a64e3c1d2287eeceb34b0dca84.tar.bz2
portage-ce313966c95b66a64e3c1d2287eeceb34b0dca84.zip
Always check the return value of doebuild_environment().
svn path=/main/trunk/; revision=4513
-rwxr-xr-xbin/emerge4
-rw-r--r--pym/portage.py3
2 files changed, 5 insertions, 2 deletions
diff --git a/bin/emerge b/bin/emerge
index c0c82058d..37c7bc7b1 100755
--- a/bin/emerge
+++ b/bin/emerge
@@ -2014,8 +2014,10 @@ class MergeTask(object):
returnme=1
continue
- portage.doebuild_environment(y, "setup", myroot,
+ retval = portage.doebuild_environment(y, "setup", myroot,
pkgsettings, self.edebug, 1, portdb)
+ if retval != os.EX_OK:
+ return retval
portage_util.ensure_dirs(
os.path.dirname(pkgsettings["PORTAGE_BUILDDIR"]),
gid=portage.portage_gid, mode=070, mask=02)
diff --git a/pym/portage.py b/pym/portage.py
index 6024f699d..2b9f532ca 100644
--- a/pym/portage.py
+++ b/pym/portage.py
@@ -2632,6 +2632,7 @@ def doebuild_environment(myebuild, mydo, myroot, mysettings, debug, use_cache, m
# Allow color.map to control colors associated with einfo, ewarn, etc...
for c in ("GOOD", "WARN", "BAD", "HILITE", "BRACKET"):
mysettings[c] = output.codes[c]
+ return os.EX_OK
def prepare_build_dirs(myroot, mysettings, cleanup):
@@ -2843,7 +2844,7 @@ def doebuild(myebuild, mydo, myroot, mysettings, debug=0, listonly=0,
mystatus = doebuild_environment(myebuild, mydo, myroot, mysettings, debug,
use_cache, mydbapi)
- if mystatus:
+ if mystatus != os.EX_OK:
return mystatus
# get possible slot information from the deps file