From a1be9ef4fed1dbf04a256e8196ddc3cca3bc0274 Mon Sep 17 00:00:00 2001 From: Danny Al-Gaaf Date: Wed, 9 Sep 2015 16:50:38 +0200 Subject: [PATCH] NewStore.cc: prefer --/++operator for non-primitive iterators Signed-off-by: Danny Al-Gaaf --- src/os/newstore/NewStore.cc | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/os/newstore/NewStore.cc b/src/os/newstore/NewStore.cc index 953dcd22d58..2288894042a 100644 --- a/src/os/newstore/NewStore.cc +++ b/src/os/newstore/NewStore.cc @@ -463,7 +463,7 @@ int NewStore::OnodeHashLRU::trim(int max) int num = onode_map.size() - max; lru_list_t::iterator p = lru.end(); if (num) - p--; + --p; while (num > 0) { Onode *o = &*p; int refs = o->nref.read(); @@ -2487,7 +2487,7 @@ void NewStore::_kv_sync_thread() if (!g_conf->newstore_sync_submit_transaction) { for (std::deque::iterator it = kv_committing.begin(); it != kv_committing.end(); - it++) { + ++it) { db->submit_transaction((*it)->t); } } @@ -2497,7 +2497,7 @@ void NewStore::_kv_sync_thread() KeyValueDB::Transaction txc_cleanup_sync = db->get_transaction(); for (std::deque::iterator it = wal_cleaning.begin(); it != wal_cleaning.end(); - it++) { + ++it) { wal_transaction_t& wt =*(*it)->wal_txn; // cleanup the data in overlays for (list::iterator p = wt.ops.begin(); p != wt.ops.end(); ++p) { -- 2.47.3