summaryrefslogtreecommitdiff
path: root/apt-pkg/algorithms.cc
diff options
context:
space:
mode:
authorMichael Vogt <michael.vogt@ubuntu.com>2006-12-20 10:58:57 +0100
committerMichael Vogt <michael.vogt@ubuntu.com>2006-12-20 10:58:57 +0100
commit020daa7b026cf1496959ccc9d062d95cb5f8ec02 (patch)
tree157f334dd72e444565d2fcc945a98e10c9fe8d81 /apt-pkg/algorithms.cc
parent4cc152f93acf2eaf3ae66424cd4aaf47cad14a7b (diff)
* apt-pkg/algorithms.cc:
- make sure we have a candidateVer if we check it for downloadability
Diffstat (limited to 'apt-pkg/algorithms.cc')
-rw-r--r--apt-pkg/algorithms.cc2
1 files changed, 1 insertions, 1 deletions
diff --git a/apt-pkg/algorithms.cc b/apt-pkg/algorithms.cc
index e1b9406e2..5fa16e66f 100644
--- a/apt-pkg/algorithms.cc
+++ b/apt-pkg/algorithms.cc
@@ -497,7 +497,7 @@ void pkgProblemResolver::MakeScores()
on the same level. We enhance the score of installed packages
if those are not obsolete
*/
- if (I->CurrentVer != 0 && Cache[I].CandidateVerIter(Cache).Downloadable())
+ if (I->CurrentVer != 0 && Cache[I].CandidateVer != 0 && Cache[I].CandidateVerIter(Cache).Downloadable())
Score += 1;
}