diff options
author | Michael Vogt <egon@debian-devbox> | 2011-08-15 14:10:42 +0200 |
---|---|---|
committer | Michael Vogt <egon@debian-devbox> | 2011-08-15 14:10:42 +0200 |
commit | c5ca2c52a98fcb50de6429cf370ed5b6b7602a00 (patch) | |
tree | 03dbb2f6898ad12126c40e6f7c64c01e863ccacd /apt-pkg/policy.cc | |
parent | 97efc27f0723f09405d7a1836ab21c2e2948eb10 (diff) | |
parent | d4882aa1e1a37b3092950180036676a930a5792f (diff) |
merged from the debian-sid branch
Diffstat (limited to 'apt-pkg/policy.cc')
-rw-r--r-- | apt-pkg/policy.cc | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/apt-pkg/policy.cc b/apt-pkg/policy.cc index 2c22fe0da..0cc77e0af 100644 --- a/apt-pkg/policy.cc +++ b/apt-pkg/policy.cc @@ -81,7 +81,7 @@ pkgPolicy::pkgPolicy(pkgCache *Owner) : Pins(0), PFPriority(0), Cache(Owner) bool pkgPolicy::InitDefaults() { // Initialize the priorities based on the status of the package file - for (pkgCache::PkgFileIterator I = Cache->FileBegin(); I != Cache->FileEnd(); I++) + for (pkgCache::PkgFileIterator I = Cache->FileBegin(); I != Cache->FileEnd(); ++I) { PFPriority[I->ID] = 500; if ((I->Flags & pkgCache::Flag::NotSource) == pkgCache::Flag::NotSource) @@ -98,10 +98,10 @@ bool pkgPolicy::InitDefaults() signed Cur = 989; StatusOverride = false; for (vector<Pin>::const_iterator I = Defaults.begin(); I != Defaults.end(); - I++, Cur--) + ++I, --Cur) { pkgVersionMatch Match(I->Data,I->Type); - for (pkgCache::PkgFileIterator F = Cache->FileBegin(); F != Cache->FileEnd(); F++) + for (pkgCache::PkgFileIterator F = Cache->FileBegin(); F != Cache->FileEnd(); ++F) { if (Match.FileMatch(F) == true && Fixed[F->ID] == false) { @@ -122,7 +122,7 @@ bool pkgPolicy::InitDefaults() } if (_config->FindB("Debug::pkgPolicy",false) == true) - for (pkgCache::PkgFileIterator F = Cache->FileBegin(); F != Cache->FileEnd(); F++) + for (pkgCache::PkgFileIterator F = Cache->FileBegin(); F != Cache->FileEnd(); ++F) std::clog << "Prio of " << F.FileName() << ' ' << PFPriority[F->ID] << std::endl; return true; @@ -162,12 +162,12 @@ pkgCache::VerIterator pkgPolicy::GetCandidateVer(pkgCache::PkgIterator const &Pk tracks the default when the default is taken away, and a permanent pin that stays at that setting. */ - for (pkgCache::VerIterator Ver = Pkg.VersionList(); Ver.end() == false; Ver++) + for (pkgCache::VerIterator Ver = Pkg.VersionList(); Ver.end() == false; ++Ver) { /* Lets see if this version is the installed version */ bool instVer = (Pkg.CurrentVer() == Ver); - for (pkgCache::VerFileIterator VF = Ver.FileList(); VF.end() == false; VF++) + for (pkgCache::VerFileIterator VF = Ver.FileList(); VF.end() == false; ++VF) { /* If this is the status file, and the current version is not the version in the status file (ie it is not installed, or somesuch) @@ -360,7 +360,7 @@ bool ReadPinDir(pkgPolicy &Plcy,string Dir) vector<string> const List = GetListOfFilesInDir(Dir, "pref", true, true); // Read the files - for (vector<string>::const_iterator I = List.begin(); I != List.end(); I++) + for (vector<string>::const_iterator I = List.begin(); I != List.end(); ++I) if (ReadPinFile(Plcy, *I) == false) return false; return true; |