From a2d1b29cd7e2c2b1167a9f6745c2765ffab128d8 Mon Sep 17 00:00:00 2001 From: Zac Medico Date: Tue, 2 Mar 2010 20:13:47 +0000 Subject: [PATCH] Bug #262647 - Explicitly exclude SRC_URI and other potentially long metadata variables from config.environ() exports, to avoid potential E2BIG errors from execve calls. (trunk r15347) svn path=/main/branches/2.1.7/; revision=15574 --- pym/portage/__init__.py | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/pym/portage/__init__.py b/pym/portage/__init__.py index 0708aead8..9fc0963f1 100644 --- a/pym/portage/__init__.py +++ b/pym/portage/__init__.py @@ -1365,9 +1365,6 @@ class config(object): virtuals ...etc you look in here. """ - # Don't include anything that could be extremely long here (like SRC_URI) - # since that could cause execve() calls to fail with E2BIG errors. For - # example, see bug #262647. _setcpv_aux_keys = ('SLOT', 'RESTRICT', 'LICENSE', 'KEYWORDS', 'INHERITED', 'IUSE', 'PROVIDE', 'EAPI', 'PROPERTIES', 'DEFINED_PHASES', 'repository') @@ -1466,6 +1463,13 @@ class config(object): # they don't needlessly propagate down into the ebuild environment. _environ_filter = [] + # Exclude anything that could be extremely long here (like SRC_URI) + # since that could cause execve() calls to fail with E2BIG errors. For + # example, see bug #262647. + _environ_filter += [ + 'DEPEND', 'RDEPEND', 'PDEPEND', 'SRC_URI', + ] + # misc variables inherited from the calling environment _environ_filter += [ "INFOPATH", "MANPATH", "USER", -- 2.26.2