]> git.saurik.com Git - apt.git/blobdiff - apt-pkg/depcache.cc
cleanup the debian/rules file a bit
[apt.git] / apt-pkg / depcache.cc
index 23abc76c165139d164aabff72366ae879277d724..58e7ebf07f983efba6ec99784c2788490e9dc12e 100644 (file)
@@ -1510,11 +1510,15 @@ void pkgDepCache::SetReInstall(PkgIterator const &Pkg,bool To)
 /* */
 void pkgDepCache::SetCandidateVersion(VerIterator TargetVer, bool const &Pseudo)
 {
-   ActionGroup group(*this);
 
    pkgCache::PkgIterator Pkg = TargetVer.ParentPkg();
    StateCache &P = PkgState[Pkg->ID];
 
+   if (P.CandidateVer == TargetVer)
+      return;
+
+   ActionGroup group(*this);
+
    RemoveSizes(Pkg);
    RemoveStates(Pkg);
 
@@ -1549,7 +1553,10 @@ void pkgDepCache::SetCandidateVersion(VerIterator TargetVer, bool const &Pseudo)
       }
    }
 }
-
+                                                                       /*}}}*/
+// DepCache::MarkAuto - set the Auto flag for a package                        /*{{{*/
+// ---------------------------------------------------------------------
+/* */
 void pkgDepCache::MarkAuto(const PkgIterator &Pkg, bool Auto)
 {
   StateCache &state = PkgState[Pkg->ID];