summaryrefslogtreecommitdiffstats
path: root/chrome/browser/net
diff options
context:
space:
mode:
Diffstat (limited to 'chrome/browser/net')
-rw-r--r--chrome/browser/net/chrome_net_log.cc14
-rw-r--r--chrome/browser/net/chrome_net_log.h4
-rw-r--r--chrome/browser/net/passive_log_collector.cc1
-rw-r--r--chrome/browser/net/sqlite_persistent_cookie_store.cc8
4 files changed, 13 insertions, 14 deletions
diff --git a/chrome/browser/net/chrome_net_log.cc b/chrome/browser/net/chrome_net_log.cc
index 6cfc893..58fe6ad 100644
--- a/chrome/browser/net/chrome_net_log.cc
+++ b/chrome/browser/net/chrome_net_log.cc
@@ -36,7 +36,7 @@ void ChromeNetLog::ThreadSafeObserver::AssertNetLogLockAcquired() const {
void ChromeNetLog::ThreadSafeObserver::SetLogLevel(
net::NetLog::LogLevel log_level) {
DCHECK(net_log_);
- AutoLock lock(net_log_->lock_);
+ base::AutoLock lock(net_log_->lock_);
log_level_ = log_level;
net_log_->UpdateLogLevel_();
}
@@ -85,7 +85,7 @@ void ChromeNetLog::AddEntry(EventType type,
const Source& source,
EventPhase phase,
EventParameters* params) {
- AutoLock lock(lock_);
+ base::AutoLock lock(lock_);
// Notify all of the log observers.
FOR_EACH_OBSERVER(ThreadSafeObserver, observers_,
@@ -102,12 +102,12 @@ net::NetLog::LogLevel ChromeNetLog::GetLogLevel() const {
}
void ChromeNetLog::AddObserver(ThreadSafeObserver* observer) {
- AutoLock lock(lock_);
+ base::AutoLock lock(lock_);
AddObserverWhileLockHeld(observer);
}
void ChromeNetLog::RemoveObserver(ThreadSafeObserver* observer) {
- AutoLock lock(lock_);
+ base::AutoLock lock(lock_);
DCHECK_EQ(observer->net_log_, this);
observer->net_log_ = NULL;
observers_.RemoveObserver(observer);
@@ -116,18 +116,18 @@ void ChromeNetLog::RemoveObserver(ThreadSafeObserver* observer) {
void ChromeNetLog::AddObserverAndGetAllPassivelyCapturedEvents(
ThreadSafeObserver* observer, EntryList* passive_entries) {
- AutoLock lock(lock_);
+ base::AutoLock lock(lock_);
AddObserverWhileLockHeld(observer);
passive_collector_->GetAllCapturedEvents(passive_entries);
}
void ChromeNetLog::GetAllPassivelyCapturedEvents(EntryList* passive_entries) {
- AutoLock lock(lock_);
+ base::AutoLock lock(lock_);
passive_collector_->GetAllCapturedEvents(passive_entries);
}
void ChromeNetLog::ClearAllPassivelyCapturedEvents() {
- AutoLock lock(lock_);
+ base::AutoLock lock(lock_);
passive_collector_->Clear();
}
diff --git a/chrome/browser/net/chrome_net_log.h b/chrome/browser/net/chrome_net_log.h
index 12daee8..9b2c480 100644
--- a/chrome/browser/net/chrome_net_log.h
+++ b/chrome/browser/net/chrome_net_log.h
@@ -9,9 +9,9 @@
#include <vector>
#include "base/atomicops.h"
-#include "base/lock.h"
#include "base/observer_list.h"
#include "base/scoped_ptr.h"
+#include "base/synchronization/lock.h"
#include "base/time.h"
#include "net/base/net_log.h"
@@ -142,7 +142,7 @@ class ChromeNetLog : public net::NetLog {
// |lock_| protects access to |observers_| and, indirectly, to
// |passive_collector_|. Should not be acquired by observers.
- Lock lock_;
+ base::Lock lock_;
// Last assigned source ID. Incremented to get the next one.
base::subtle::Atomic32 last_id_;
diff --git a/chrome/browser/net/passive_log_collector.cc b/chrome/browser/net/passive_log_collector.cc
index 21e2935..8ac8e53 100644
--- a/chrome/browser/net/passive_log_collector.cc
+++ b/chrome/browser/net/passive_log_collector.cc
@@ -7,7 +7,6 @@
#include <algorithm>
#include "base/compiler_specific.h"
-#include "base/lock.h"
#include "base/string_util.h"
#include "base/format_macros.h"
#include "net/url_request/url_request_netlog_params.h"
diff --git a/chrome/browser/net/sqlite_persistent_cookie_store.cc b/chrome/browser/net/sqlite_persistent_cookie_store.cc
index 622ee50..734e00b 100644
--- a/chrome/browser/net/sqlite_persistent_cookie_store.cc
+++ b/chrome/browser/net/sqlite_persistent_cookie_store.cc
@@ -107,7 +107,7 @@ class SQLitePersistentCookieStore::Backend
// True if the persistent store should be deleted upon destruction.
bool clear_local_state_on_exit_;
// Guard |pending_|, |num_pending_| and |clear_local_state_on_exit_|.
- Lock lock_;
+ base::Lock lock_;
DISALLOW_COPY_AND_ASSIGN(Backend);
};
@@ -306,7 +306,7 @@ void SQLitePersistentCookieStore::Backend::BatchOperation(
PendingOperationsList::size_type num_pending;
{
- AutoLock locked(lock_);
+ base::AutoLock locked(lock_);
pending_.push_back(po.release());
num_pending = ++num_pending_;
}
@@ -329,7 +329,7 @@ void SQLitePersistentCookieStore::Backend::Commit() {
PendingOperationsList ops;
{
- AutoLock locked(lock_);
+ base::AutoLock locked(lock_);
pending_.swap(ops);
num_pending_ = 0;
}
@@ -449,7 +449,7 @@ void SQLitePersistentCookieStore::Backend::InternalBackgroundClose() {
void SQLitePersistentCookieStore::Backend::SetClearLocalStateOnExit(
bool clear_local_state) {
- AutoLock locked(lock_);
+ base::AutoLock locked(lock_);
clear_local_state_on_exit_ = clear_local_state;
}
SQLitePersistentCookieStore::SQLitePersistentCookieStore(const FilePath& path)