commit: d8d02bd82f11921db5140941cef4077359b0211d Author: Zac Medico <zmedico <AT> gentoo <DOT> org> AuthorDate: Sat Feb 15 20:37:39 2020 +0000 Commit: Zac Medico <zmedico <AT> gentoo <DOT> org> CommitDate: Sat Feb 15 20:42:24 2020 +0000 URL: https://gitweb.gentoo.org/proj/portage.git/commit/?id=d8d02bd8
fetch: remove secpass import (bug 601252) Refer to the portage.secpass.data attribute directly rather than via import value, since the value will change after fork and os.setuid calls when the fetch function is called with dropped privileges as discussed in bug 601252. Bug: https://bugs.gentoo.org/601252 Signed-off-by: Zac Medico <zmedico <AT> gentoo.org> lib/portage/package/ebuild/fetch.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/lib/portage/package/ebuild/fetch.py b/lib/portage/package/ebuild/fetch.py index e0260829b..06118b1a6 100644 --- a/lib/portage/package/ebuild/fetch.py +++ b/lib/portage/package/ebuild/fetch.py @@ -1,4 +1,4 @@ -# Copyright 2010-2019 Gentoo Authors +# Copyright 2010-2020 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 from __future__ import print_function @@ -46,7 +46,7 @@ from portage.checksum import (get_valid_checksum_keys, perform_md5, verify_all, checksum_str) from portage.const import BASH_BINARY, CUSTOM_MIRRORS_FILE, \ GLOBAL_CONFIG_PATH -from portage.data import portage_gid, portage_uid, secpass, userpriv_groups +from portage.data import portage_gid, portage_uid, userpriv_groups from portage.exception import FileNotFound, OperationNotPermitted, \ PortageException, TryAgain from portage.localization import _ @@ -882,7 +882,7 @@ def fetch(myuris, mysettings, listonly=0, fetchonly=0, if not has_space_superuser: has_space = False - elif secpass < 2: + elif portage.data.secpass < 2: has_space = False elif userfetch: has_space = False
