summaryrefslogtreecommitdiffstats
path: root/pym/_emerge
diff options
context:
space:
mode:
authorZac Medico <zmedico@gentoo.org>2008-10-19 17:33:14 +0000
committerZac Medico <zmedico@gentoo.org>2008-10-19 17:33:14 +0000
commit0ed807e70280efe2e1fe54221acc57fe6ba12ceb (patch)
treecc6cf056e83a682ba23777a81e6fbef795fdc479 /pym/_emerge
parent68b0d63dd7c8387dd5a84e20dcd5fcfd6a5ed9e4 (diff)
downloadportage-0ed807e70280efe2e1fe54221acc57fe6ba12ceb.tar.gz
portage-0ed807e70280efe2e1fe54221acc57fe6ba12ceb.tar.bz2
portage-0ed807e70280efe2e1fe54221acc57fe6ba12ceb.zip
Remove the "found_available_arg" variable from depgraph._select_pkg() and use
the "matched_packages" variable instead. This solve a problem where the "found_available_arg" flag is unreliable due to the slot filtering behavior of depgraph._iter_atoms_for_pkg(). For example, a higher version in a different slot than the available ebuild might be masked or unavailable, and depgraph._iter_atoms_for_pkg() will not identify the available ebuild as a match due to this installed package (which is not available for reinstall). svn path=/main/trunk/; revision=11702
Diffstat (limited to 'pym/_emerge')
-rw-r--r--pym/_emerge/__init__.py8
1 files changed, 2 insertions, 6 deletions
diff --git a/pym/_emerge/__init__.py b/pym/_emerge/__init__.py
index 03ee50eca..ca4550afb 100644
--- a/pym/_emerge/__init__.py
+++ b/pym/_emerge/__init__.py
@@ -5417,9 +5417,7 @@ class depgraph(object):
# Therefore, "selective" logic does not consider
# whether or not an installed package matches an
# argument atom. It only considers whether or not
- # available packages match argument atoms, which is
- # represented by the found_available_arg flag.
- found_available_arg = False
+ # available packages match argument atoms.
for find_existing_node in True, False:
if existing_node:
break
@@ -5428,7 +5426,7 @@ class depgraph(object):
break
if installed and not find_existing_node:
want_reinstall = reinstall or empty or \
- (found_available_arg and not selective)
+ (matched_packages and not selective)
if want_reinstall and matched_packages:
continue
if hasattr(db, "xmatch"):
@@ -5568,8 +5566,6 @@ class depgraph(object):
if not installed:
# masked by corruption
continue
- if not installed and myarg:
- found_available_arg = True
if atom.use and not pkg.built:
use = pkg.use.enabled