summaryrefslogtreecommitdiffstats
path: root/chrome/browser/sync/syncable/directory_manager.h
diff options
context:
space:
mode:
authortimsteele@google.com <timsteele@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2009-10-07 18:42:35 +0000
committertimsteele@google.com <timsteele@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2009-10-07 18:42:35 +0000
commitde32e5eec767c4472d708488f98619c7bc2f7227 (patch)
treed295030fbf6f1fe43dfed00a88ad68d909129429 /chrome/browser/sync/syncable/directory_manager.h
parent9424883141ce8f7c1052827f519f001c89a47213 (diff)
downloadchromium_src-de32e5eec767c4472d708488f98619c7bc2f7227.zip
chromium_src-de32e5eec767c4472d708488f98619c7bc2f7227.tar.gz
chromium_src-de32e5eec767c4472d708488f98619c7bc2f7227.tar.bz2
Sync: Replace pthread mutex with base::Lock in a few more places.
This leaves just ServerConnectionManager behind. BUG=19895 TEST=sync_unit_tests Review URL: http://codereview.chromium.org/251098 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@28278 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/sync/syncable/directory_manager.h')
-rw-r--r--chrome/browser/sync/syncable/directory_manager.h10
1 files changed, 3 insertions, 7 deletions
diff --git a/chrome/browser/sync/syncable/directory_manager.h b/chrome/browser/sync/syncable/directory_manager.h
index 197b46b..f059257 100644
--- a/chrome/browser/sync/syncable/directory_manager.h
+++ b/chrome/browser/sync/syncable/directory_manager.h
@@ -12,11 +12,10 @@
#ifndef CHROME_BROWSER_SYNC_SYNCABLE_DIRECTORY_MANAGER_H_
#define CHROME_BROWSER_SYNC_SYNCABLE_DIRECTORY_MANAGER_H_
-#include <pthread.h>
-
#include <vector>
#include "base/atomicops.h"
+#include "base/lock.h"
#include "base/basictypes.h"
#include "chrome/browser/sync/syncable/dir_open_result.h"
#include "chrome/browser/sync/syncable/path_name_cmp.h"
@@ -66,10 +65,6 @@ class DirectoryManager {
// file handles and resources are freed by other threads.
void Close(const PathString& name);
- // Marks all directories as closed. It might take a while until all the
- // file handles and resources are freed by other threads.
- void CloseAllDirectories();
-
// Should be called at App exit.
void FinalSaveChangesForAll();
@@ -87,8 +82,9 @@ class DirectoryManager {
friend class ScopedDirLookup;
const PathString root_path_;
+
// protects managed_directory_
- mutable pthread_mutex_t mutex_;
+ Lock lock_;
Directory* managed_directory_;
Channel* const channel_;