diff options
author | David Kalnischkies <kalnischkies@gmail.com> | 2011-08-11 20:53:28 +0200 |
---|---|---|
committer | David Kalnischkies <kalnischkies@gmail.com> | 2011-08-11 20:53:28 +0200 |
commit | f7f0d6c7560a8f71707e7852a512469147aa9f84 (patch) | |
tree | 5bec681b4e798a2b35bea180213df399c51920d9 /apt-pkg/vendorlist.cc | |
parent | dd6882853b4555a6113740afca417acbaa060043 (diff) |
cppcheck complains about some possible speed improvements which could be
done on the mirco-optimazation level, so lets fix them:
(performance) Possible inefficient checking for emptiness.
(performance) Prefer prefix ++/-- operators for non-primitive types.
Diffstat (limited to 'apt-pkg/vendorlist.cc')
-rw-r--r-- | apt-pkg/vendorlist.cc | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/apt-pkg/vendorlist.cc b/apt-pkg/vendorlist.cc index 48ac12cee..4cc500727 100644 --- a/apt-pkg/vendorlist.cc +++ b/apt-pkg/vendorlist.cc @@ -11,7 +11,7 @@ pkgVendorList::~pkgVendorList() { for (vector<const Vendor *>::const_iterator I = VendorList.begin(); - I != VendorList.end(); I++) + I != VendorList.end(); ++I) delete *I; } @@ -49,7 +49,7 @@ bool pkgVendorList::Read(string File) /*{{{*/ bool pkgVendorList::CreateList(Configuration& Cnf) /*{{{*/ { for (vector<const Vendor *>::const_iterator I = VendorList.begin(); - I != VendorList.end(); I++) + I != VendorList.end(); ++I) delete *I; VendorList.erase(VendorList.begin(),VendorList.end()); @@ -129,7 +129,7 @@ const Vendor* pkgVendorList::LookupFingerprint(string Fingerprint) /*{{{*/ /*}}}*/ const Vendor* pkgVendorList::FindVendor(const std::vector<string> GPGVOutput) /*{{{*/ { - for (std::vector<string>::const_iterator I = GPGVOutput.begin(); I != GPGVOutput.end(); I++) + for (std::vector<string>::const_iterator I = GPGVOutput.begin(); I != GPGVOutput.end(); ++I) { string::size_type pos = (*I).find("VALIDSIG "); if (_config->FindB("Debug::Vendor", false)) |