Index: chrome/browser/sync/profile_sync_service.cc |
diff --git a/chrome/browser/sync/profile_sync_service.cc b/chrome/browser/sync/profile_sync_service.cc |
index 5173ed7c0d765c02a5209aa955e2c9a8cf9a43cc..cb5eca1195fe9c48a4c3fcd7c804ed15e36110dc 100644 |
--- a/chrome/browser/sync/profile_sync_service.cc |
+++ b/chrome/browser/sync/profile_sync_service.cc |
@@ -70,6 +70,8 @@ |
#include "net/url_request/url_request_context_getter.h" |
#include "sync/api/sync_error.h" |
#include "sync/internal_api/public/configure_reason.h" |
+#include "sync/internal_api/public/http_bridge_factory_factory.h" |
+#include "sync/internal_api/public/http_post_provider_factory_factory.h" |
#include "sync/internal_api/public/sync_encryption_handler.h" |
#include "sync/internal_api/public/util/experiments.h" |
#include "sync/internal_api/public/util/sync_string_conversions.h" |
@@ -179,7 +181,9 @@ ProfileSyncService::ProfileSyncService( |
request_access_token_backoff_(&kRequestAccessTokenBackoffPolicy), |
weak_factory_(this), |
connection_status_(syncer::CONNECTION_NOT_ATTEMPTED), |
- last_get_token_error_(GoogleServiceAuthError::AuthErrorNone()) { |
+ last_get_token_error_(GoogleServiceAuthError::AuthErrorNone()), |
+ http_post_provider_factory_factory_( |
+ new syncer::HttpBridgeFactoryFactory) { |
DCHECK(profile); |
// By default, dev, canary, and unbranded Chromium users will go to the |
// development servers. Development servers have more features than standard |
@@ -541,7 +545,8 @@ void ProfileSyncService::InitializeBackend(bool delete_stale_data) { |
scoped_ptr<syncer::SyncManagerFactory>( |
new syncer::SyncManagerFactory).Pass(), |
backend_unrecoverable_error_handler.Pass(), |
- &browser_sync::ChromeReportUnrecoverableError); |
+ &browser_sync::ChromeReportUnrecoverableError, |
+ http_post_provider_factory_factory_.get()); |
} |
void ProfileSyncService::CreateBackend() { |
@@ -2259,3 +2264,10 @@ ProfileSyncService::GetSyncTokenStatus() const { |
status.next_token_request_time = next_token_request_time_; |
return status; |
} |
+ |
+void ProfileSyncService::OverrideHttpPostProviderFactoryFactoryForTest( |
+ scoped_ptr<syncer::HttpPostProviderFactoryFactory> |
+ http_post_provider_factory_factory) { |
+ http_post_provider_factory_factory_ = |
+ http_post_provider_factory_factory.Pass(); |
pval...(no longer on Chromium)
2013/11/25 21:30:10
please double check that this is the right way to
|
+} |