From: Zac Medico Date: Tue, 1 Apr 2008 21:58:58 +0000 (-0000) Subject: Use pkgcmp() instead of == and best() for correctness in case of implicit X-Git-Tag: v2.1.5~262 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=e9ad7be4e102c375ce10b61f8cc441150dc4a681;p=portage.git Use pkgcmp() instead of == and best() for correctness in case of implicit -r0. (trunk r9672) svn path=/main/branches/2.1.2/; revision=9673 --- diff --git a/pym/portage.py b/pym/portage.py index f764dbfc2..30b1e2b19 100644 --- a/pym/portage.py +++ b/pym/portage.py @@ -5426,8 +5426,10 @@ def dep_zapdeps(unreduced, reduced, myroot, use_binaries=0, trees=None): for myslot in intersecting_slots: myversion = versions[myslot] o_version = o_versions[myslot] - if myversion != o_version: - if myversion == best([myversion, o_version]): + difference = pkgcmp(catpkgsplit(myversion)[1:], + catpkgsplit(o_version)[1:]) + if difference: + if difference > 0: has_upgrade = True else: has_downgrade = True