diff options
author | Zac Medico <zmedico@gentoo.org> | 2010-09-08 21:05:32 -0700 |
---|---|---|
committer | Zac Medico <zmedico@gentoo.org> | 2010-09-08 21:05:32 -0700 |
commit | 0073dd92b6ab1a3e2734c025f86795308ba19bf4 (patch) | |
tree | 280977a534717ebdefd5889e1fcbdddd9f3d05bb | |
parent | 3f7f72cf339da70b13b8c8c92e6b674ad394c5aa (diff) | |
download | portage-0073dd92b6ab1a3e2734c025f86795308ba19bf4.tar.gz portage-0073dd92b6ab1a3e2734c025f86795308ba19bf4.tar.bz2 portage-0073dd92b6ab1a3e2734c025f86795308ba19bf4.zip |
Make action_info() validate PORTAGE_TMPDIR since it uses it to solve
bug #336503.
-rw-r--r-- | pym/_emerge/actions.py | 7 |
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() |