Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(334)

Side by Side Diff: chrome/browser/sync/engine/net/server_connection_manager.h

Issue 246098: Sync: Remove pthreads from auth_watcher. (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 11 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2009 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef CHROME_BROWSER_SYNC_ENGINE_NET_SERVER_CONNECTION_MANAGER_H_ 5 #ifndef CHROME_BROWSER_SYNC_ENGINE_NET_SERVER_CONNECTION_MANAGER_H_
6 #define CHROME_BROWSER_SYNC_ENGINE_NET_SERVER_CONNECTION_MANAGER_H_ 6 #define CHROME_BROWSER_SYNC_ENGINE_NET_SERVER_CONNECTION_MANAGER_H_
7 7
8 #include <iosfwd> 8 #include <iosfwd>
9 #include <string> 9 #include <string>
10 #include <vector> 10 #include <vector>
(...skipping 238 matching lines...) Expand 10 before | Expand all | Expand 10 after
249 // Factory method to create a Post object we can use for communication with 249 // Factory method to create a Post object we can use for communication with
250 // the server. 250 // the server.
251 virtual Post* MakePost() { 251 virtual Post* MakePost() {
252 return NULL; // For testing. 252 return NULL; // For testing.
253 }; 253 };
254 254
255 void set_auth_token(const std::string& auth_token) { 255 void set_auth_token(const std::string& auth_token) {
256 auth_token_.assign(auth_token); 256 auth_token_.assign(auth_token);
257 } 257 }
258 258
259 const std::string& auth_token() const {
260 return auth_token_;
261 }
262
259 protected: 263 protected:
260 264
261 PThreadMutex shutdown_event_mutex_; 265 PThreadMutex shutdown_event_mutex_;
262 PThreadCondVar shutdown_event_condition_; 266 PThreadCondVar shutdown_event_condition_;
263 267
264 // Protects access to sync_server_, sync_server_port_ and use_ssl_: 268 // Protects access to sync_server_, sync_server_port_ and use_ssl_:
265 mutable PThreadMutex server_parameters_mutex_; 269 mutable PThreadMutex server_parameters_mutex_;
266 typedef PThreadScopedLock<PThreadMutex> ParametersLock; 270 typedef PThreadScopedLock<PThreadMutex> ParametersLock;
267 271
268 // The sync_server_ is the server that requests will be made to. 272 // The sync_server_ is the server that requests will be made to.
(...skipping 67 matching lines...) Expand 10 before | Expand all | Expand 10 after
336 bool FillMessageWithShareDetails(sync_pb::ClientToServerMessage* csm, 340 bool FillMessageWithShareDetails(sync_pb::ClientToServerMessage* csm,
337 syncable::DirectoryManager* manager, 341 syncable::DirectoryManager* manager,
338 const PathString &share); 342 const PathString &share);
339 343
340 } // namespace browser_sync 344 } // namespace browser_sync
341 345
342 std::ostream& operator<<(std::ostream& s, 346 std::ostream& operator<<(std::ostream& s,
343 const struct browser_sync::HttpResponse& hr); 347 const struct browser_sync::HttpResponse& hr);
344 348
345 #endif // CHROME_BROWSER_SYNC_ENGINE_NET_SERVER_CONNECTION_MANAGER_H_ 349 #endif // CHROME_BROWSER_SYNC_ENGINE_NET_SERVER_CONNECTION_MANAGER_H_
OLDNEW
« no previous file with comments | « chrome/browser/sync/engine/net/gaia_authenticator.h ('k') | chrome/browser/sync/engine/syncapi.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698