summaryrefslogtreecommitdiff
path: root/apt-pkg/aptconfiguration.cc
diff options
context:
space:
mode:
authorDavid Kalnischkies <kalnischkies@gmail.com>2011-08-11 20:53:28 +0200
committerDavid Kalnischkies <kalnischkies@gmail.com>2011-08-11 20:53:28 +0200
commitf7f0d6c7560a8f71707e7852a512469147aa9f84 (patch)
tree5bec681b4e798a2b35bea180213df399c51920d9 /apt-pkg/aptconfiguration.cc
parentdd6882853b4555a6113740afca417acbaa060043 (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/aptconfiguration.cc')
-rw-r--r--apt-pkg/aptconfiguration.cc4
1 files changed, 2 insertions, 2 deletions
diff --git a/apt-pkg/aptconfiguration.cc b/apt-pkg/aptconfiguration.cc
index 9ccbeecf1..6ec5fa03a 100644
--- a/apt-pkg/aptconfiguration.cc
+++ b/apt-pkg/aptconfiguration.cc
@@ -53,7 +53,7 @@ const Configuration::getCompressionTypes(bool const &Cached) {
// load the order setting into our vector
std::vector<std::string> const order = _config->FindVector("Acquire::CompressionTypes::Order");
for (std::vector<std::string>::const_iterator o = order.begin();
- o != order.end(); o++) {
+ o != order.end(); ++o) {
if ((*o).empty() == true)
continue;
// ignore types we have no method ready to use
@@ -274,7 +274,7 @@ std::vector<std::string> const Configuration::getLanguages(bool const &All,
// then needed and ensure the codes are not listed twice.
bool noneSeen = false;
for (std::vector<string>::const_iterator l = lang.begin();
- l != lang.end(); l++) {
+ l != lang.end(); ++l) {
if (*l == "environment") {
for (std::vector<string>::const_iterator e = environment.begin();
e != environment.end(); ++e) {