From b5a93ce96f37c9dd69845c02057aef154ef6f0cc Mon Sep 17 00:00:00 2001 From: Zac Medico Date: Sat, 12 Sep 2009 14:37:45 +0000 Subject: Make grabfile_package() accept *atom only for files named 'packages' since they are not valid in any other files. svn path=/main/trunk/; revision=14225 --- pym/portage/util.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/pym/portage/util.py b/pym/portage/util.py index f6f21f586..3232a4e51 100644 --- a/pym/portage/util.py +++ b/pym/portage/util.py @@ -306,13 +306,14 @@ def grabdict_package(myfilename, juststrings=0, recursive=0): def grabfile_package(myfilename, compatlevel=0, recursive=0): pkgs=grabfile(myfilename, compatlevel, recursive=recursive) + mybasename = os.path.basename(myfilename) atoms = [] for pkg in pkgs: pkg_orig = pkg # for packages and package.mask files if pkg[:1] == "-": pkg = pkg[1:] - if pkg[:1] == "*": + if pkg[:1] == '*' and mybasename == 'packages': pkg = pkg[1:] try: pkg = Atom(pkg) -- cgit v1.2.3-1-g7c22