From: Zac Medico Date: Mon, 31 Mar 2008 21:07:29 +0000 (-0000) Subject: Fix package selection logic to always properly reject the installed package X-Git-Tag: v2.2_pre6~283 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=a25ac0cdb617c5c26f40ae8eebd77a8948cf43ab;p=portage.git Fix package selection logic to always properly reject the installed package when another is available and the user wants to reinstall. svn path=/main/trunk/; revision=9652 --- diff --git a/pym/_emerge/__init__.py b/pym/_emerge/__init__.py index e9d0fe7fd..fa7950d4d 100644 --- a/pym/_emerge/__init__.py +++ b/pym/_emerge/__init__.py @@ -2706,8 +2706,10 @@ class depgraph(object): cpv=cpv, metadata=metadata, built=built, installed=installed, onlydeps=onlydeps) - if installed and want_reinstall: - matched_packages.insert(0, pkg) + if installed and want_reinstall and matched_packages: + # Reject the installed package unless + # there are no other matches. + break else: matched_packages.append(pkg) if reinstall_for_flags: