Parcourir la source

prefer upgrading installed provides satisfier

If you have chosen to install a foreign architecture provider it is
more reasonable to keep this provider instead of removing this one to
replace it with a newer version from a (usually) more preferred arch.

Git-Dch: Ignore
David Kalnischkies il y a 10 ans
Parent
commit
529bf9b00d
1 fichiers modifiés avec 2 ajouts et 0 suppressions
  1. 2 0
      apt-pkg/depcache.cc

+ 2 - 0
apt-pkg/depcache.cc

@@ -1016,6 +1016,8 @@ struct CompareProviders {
 	 if (instA != instB)
 	    return instA == false;
       }
+      if ((A->CurrentVer == 0 || B->CurrentVer == 0) && A->CurrentVer != B->CurrentVer)
+	 return A->CurrentVer == 0;
       // Prefer packages in the same group as the target; e.g. foo:i386, foo:amd64
       if (A->Group != B->Group)
       {