summaryrefslogtreecommitdiffstats
path: root/pym/portage/tests/bin
diff options
context:
space:
mode:
authorZac Medico <zmedico@gentoo.org>2007-03-18 00:25:43 +0000
committerZac Medico <zmedico@gentoo.org>2007-03-18 00:25:43 +0000
commit393ed1e409b2f295a47f133ce4d2d920fc15770a (patch)
tree87d621ffc48884cb7d2573d027be5a60e4358449 /pym/portage/tests/bin
parent4505eb2b4855df288327682c646b49c67a94f9ba (diff)
downloadportage-393ed1e409b2f295a47f133ce4d2d920fc15770a.tar.gz
portage-393ed1e409b2f295a47f133ce4d2d920fc15770a.tar.bz2
portage-393ed1e409b2f295a47f133ce4d2d920fc15770a.zip
Use locals() instead of setattr to insert generated functions into the current module. Thanks to Brian Harring for the suggestion.
svn path=/main/trunk/; revision=6241
Diffstat (limited to 'pym/portage/tests/bin')
-rw-r--r--pym/portage/tests/bin/setup_env.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/pym/portage/tests/bin/setup_env.py b/pym/portage/tests/bin/setup_env.py
index e0a89f1e2..a69a19ec6 100644
--- a/pym/portage/tests/bin/setup_env.py
+++ b/pym/portage/tests/bin/setup_env.py
@@ -66,4 +66,4 @@ for bin in os.listdir(bindir):
bin.startswith("new") or \
bin.startswith("prep") or \
bin in ["ecompress","ecompressdir","fowners","fperms"]:
- setattr(sys.modules[__name__], bin, create_portage_wrapper(bin))
+ locals()[bin] = create_portage_wrapper(bin)