| Index: chrome/browser/safe_browsing/safe_browsing_database_bloom.cc
|
| ===================================================================
|
| --- chrome/browser/safe_browsing/safe_browsing_database_bloom.cc (revision 3500)
|
| +++ chrome/browser/safe_browsing/safe_browsing_database_bloom.cc (working copy)
|
| @@ -4,9 +4,11 @@
|
|
|
| #include "chrome/browser/safe_browsing/safe_browsing_database_bloom.h"
|
|
|
| +#include "base/compiler_specific.h"
|
| #include "base/file_util.h"
|
| #include "base/logging.h"
|
| #include "base/message_loop.h"
|
| +#include "base/platform_thread.h"
|
| #include "base/sha2.h"
|
| #include "base/string_util.h"
|
| #include "chrome/browser/safe_browsing/bloom_filter.h"
|
| @@ -38,13 +40,11 @@
|
|
|
| SafeBrowsingDatabaseBloom::SafeBrowsingDatabaseBloom()
|
| : db_(NULL),
|
| + transaction_count_(0),
|
| init_(false),
|
| - transaction_count_(0),
|
| chunk_inserted_callback_(NULL),
|
| -#pragma warning(suppress: 4355) // can use this
|
| - reset_factory_(this),
|
| -#pragma warning(suppress: 4355) // can use this
|
| - resume_factory_(this),
|
| + ALLOW_THIS_IN_INITIALIZER_LIST(reset_factory_(this)),
|
| + ALLOW_THIS_IN_INITIALIZER_LIST(resume_factory_(this)),
|
| did_resume_(false) {
|
| }
|
|
|
| @@ -1017,7 +1017,7 @@
|
| ++eit;
|
| }
|
| if (entries.empty())
|
| - it = hash_cache_.erase(it);
|
| + hash_cache_.erase(it++);
|
| else
|
| ++it;
|
| }
|
| @@ -1049,7 +1049,7 @@
|
|
|
| void SafeBrowsingDatabaseBloom::WaitAfterResume() {
|
| if (did_resume_) {
|
| - Sleep(kOnResumeHoldupMs);
|
| + PlatformThread::Sleep(kOnResumeHoldupMs);
|
| did_resume_ = false;
|
| }
|
| }
|
|
|