summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authormatthewyuan <matthewyuan@chromium.org>2014-11-08 14:36:05 -0800
committerCommit bot <commit-bot@chromium.org>2014-11-08 22:36:23 +0000
commitbca70e90f5c0de7b071d277e0d7886e1e0823572 (patch)
treef90eeb4bb726e46bdd83620abe8adee7a1d48170
parent87607055f567c359259ea072d5479aa88da9cd0c (diff)
downloadchromium_src-bca70e90f5c0de7b071d277e0d7886e1e0823572.zip
chromium_src-bca70e90f5c0de7b071d277e0d7886e1e0823572.tar.gz
chromium_src-bca70e90f5c0de7b071d277e0d7886e1e0823572.tar.bz2
Revert of Fixing all of problems found by vc++ /analyze in GCM code (patchset #1 id:1 of https://codereview.chromium.org/713573003/)
Reason for revert: Reverting since it's causing a crash on canary. Original issue's description: > Fixing all of problems found by vc++ /analyze in GCM code > > There was only a minor (harmless) case of variable shadowing. > > BUG=427616 > R=zea@chromium.org > > Committed: https://crrev.com/3e021981ccc2be8de7443ff1a18439551b22ea75 > Cr-Commit-Position: refs/heads/master@{#303338} TBR=zea@chromium.org,brucedawson@chromium.org,fgorski@chromium.org NOTREECHECKS=true NOTRY=true BUG=427616 Review URL: https://codereview.chromium.org/712793003 Cr-Commit-Position: refs/heads/master@{#303396}
-rw-r--r--google_apis/gcm/engine/gcm_store_impl.cc10
1 files changed, 5 insertions, 5 deletions
diff --git a/google_apis/gcm/engine/gcm_store_impl.cc b/google_apis/gcm/engine/gcm_store_impl.cc
index 25bc847..14e382e 100644
--- a/google_apis/gcm/engine/gcm_store_impl.cc
+++ b/google_apis/gcm/engine/gcm_store_impl.cc
@@ -552,11 +552,11 @@ void GCMStoreImpl::Backend::SetGServicesSettings(
// Remove all existing settings.
leveldb::ReadOptions read_options;
read_options.verify_checksums = true;
- scoped_ptr<leveldb::Iterator> db_iter(db_->NewIterator(read_options));
- for (db_iter->Seek(MakeSlice(kGServiceSettingKeyStart));
- db_iter->Valid() && db_iter->key().ToString() < kGServiceSettingKeyEnd;
- db_iter->Next()) {
- write_batch.Delete(db_iter->key());
+ scoped_ptr<leveldb::Iterator> iter(db_->NewIterator(read_options));
+ for (iter->Seek(MakeSlice(kGServiceSettingKeyStart));
+ iter->Valid() && iter->key().ToString() < kGServiceSettingKeyEnd;
+ iter->Next()) {
+ write_batch.Delete(iter->key());
}
// Add the new settings.