summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--pym/_emerge/actions.py7
1 files changed, 7 insertions, 0 deletions
diff --git a/pym/_emerge/actions.py b/pym/_emerge/actions.py
index d9d0dffe5..5252b4985 100644
--- a/pym/_emerge/actions.py
+++ b/pym/_emerge/actions.py
@@ -35,6 +35,7 @@ from portage.output import blue, bold, colorize, create_color_func, darkgreen, \
good = create_color_func("GOOD")
bad = create_color_func("BAD")
from portage.package.ebuild._ipc.QueryCommand import QueryCommand
+from portage.package.ebuild.doebuild import _check_temp_dir
from portage._sets import load_default_config, SETPREFIX
from portage._sets.base import InternalPackageSet
from portage.util import cmp_sort_key, writemsg, \
@@ -1853,6 +1854,12 @@ def action_sync(settings, trees, mtimedb, myopts, myaction):
os.makedirs(myportdir,0o755)
st = os.stat(myportdir)
+ # PORTAGE_TMPDIR is used below, so validate it and
+ # bail out if necessary.
+ rval = _check_temp_dir(settings)
+ if rval != os.EX_OK:
+ return rval
+
usersync_uid = None
spawn_kwargs = {}
spawn_kwargs["env"] = settings.environ()