Chromium Code Reviews| Index: chrome/browser/background_sync/background_sync_controller_impl.cc |
| diff --git a/chrome/browser/background_sync/background_sync_controller_impl.cc b/chrome/browser/background_sync/background_sync_controller_impl.cc |
| index 0a4740ff2280a17bf879d1bcbbc9b08bc3bad16a..5a7bc21b8d033430f91b390cd120548ffca769e2 100644 |
| --- a/chrome/browser/background_sync/background_sync_controller_impl.cc |
| +++ b/chrome/browser/background_sync/background_sync_controller_impl.cc |
| @@ -28,6 +28,8 @@ const char BackgroundSyncControllerImpl::kRetryDelayFactorParameterName[] = |
| "retry_delay_factor"; |
| const char BackgroundSyncControllerImpl::kMinSyncRecoveryTimeName[] = |
| "min_recovery_time_ms"; |
| +const char BackgroundSyncControllerImpl::kMaxSyncEventDuration[] = |
| + "max_sync_event_duration_sec"; |
| BackgroundSyncControllerImpl::BackgroundSyncControllerImpl(Profile* profile) |
| : profile_(profile) {} |
| @@ -81,6 +83,15 @@ void BackgroundSyncControllerImpl::GetParameterOverrides( |
| } |
| } |
| + if (ContainsKey(field_params, kMaxSyncEventDuration)) { |
| + int64_t max_sync_event_duration_sec; |
| + if (base::StringToInt64(field_params[kMaxSyncEventDuration], |
|
iclelland
2015/12/21 19:50:15
I think this should be StringToInt (and `int max_s
jkarlin
2015/12/28 15:51:29
Done.
|
| + &max_sync_event_duration_sec)) { |
| + parameters->max_sync_event_duration = |
| + base::TimeDelta::FromSeconds(max_sync_event_duration_sec); |
| + } |
| + } |
| + |
| return; |
| } |