summaryrefslogtreecommitdiff
path: root/apt-pkg/depcache.cc
diff options
context:
space:
mode:
authorbubulle@debian.org <>2007-07-06 07:18:13 +0200
committerbubulle@debian.org <>2007-07-06 07:18:13 +0200
commitbb454321179ba5cca89e9250ccf2aafa4364e343 (patch)
tree11ca9f01224a55e69f8401ee45f9cf187d041d73 /apt-pkg/depcache.cc
parentc0681fb7e34114df9a562577d3a505402ae17e57 (diff)
parent6724d2173133f24bc8a3875c13513761f9340627 (diff)
Sync with Michael
Diffstat (limited to 'apt-pkg/depcache.cc')
-rw-r--r--apt-pkg/depcache.cc9
1 files changed, 6 insertions, 3 deletions
diff --git a/apt-pkg/depcache.cc b/apt-pkg/depcache.cc
index 50a75843f..7f5719454 100644
--- a/apt-pkg/depcache.cc
+++ b/apt-pkg/depcache.cc
@@ -1285,6 +1285,7 @@ void pkgDepCache::MarkPackage(const pkgCache::PkgIterator &pkg,
bool follow_suggests)
{
pkgDepCache::StateCache &state = PkgState[pkg->ID];
+ VerIterator currver = pkg.CurrentVer();
VerIterator candver = state.CandidateVerIter(*this);
VerIterator instver = state.InstVerIter(*this);
@@ -1305,9 +1306,11 @@ void pkgDepCache::MarkPackage(const pkgCache::PkgIterator &pkg,
}
#endif
- // Ignore versions other than the InstVer, and ignore packages
- // that are already going to be removed or just left uninstalled.
- if(!(ver == instver && !instver.end()))
+ // For packages that are not going to be removed, ignore versions
+ // other than the InstVer. For packages that are going to be
+ // removed, ignore versions other than the current version.
+ if(!(ver == instver && !instver.end()) &&
+ !(ver == currver && instver.end() && !ver.end()))
return;
// if we are marked already we are done