summaryrefslogtreecommitdiffstats
path: root/google_apis/gaia/oauth2_token_service.cc
diff options
context:
space:
mode:
Diffstat (limited to 'google_apis/gaia/oauth2_token_service.cc')
-rw-r--r--google_apis/gaia/oauth2_token_service.cc9
1 files changed, 6 insertions, 3 deletions
diff --git a/google_apis/gaia/oauth2_token_service.cc b/google_apis/gaia/oauth2_token_service.cc
index 0c7519b..72885a4 100644
--- a/google_apis/gaia/oauth2_token_service.cc
+++ b/google_apis/gaia/oauth2_token_service.cc
@@ -4,9 +4,12 @@
#include "google_apis/gaia/oauth2_token_service.h"
+#include <stdint.h>
+
#include <vector>
#include "base/bind.h"
+#include "base/macros.h"
#include "base/memory/weak_ptr.h"
#include "base/message_loop/message_loop.h"
#include "base/metrics/histogram_macros.h"
@@ -159,7 +162,7 @@ class OAuth2TokenService::Fetcher : public OAuth2AccessTokenConsumer {
void InformWaitingRequests();
void InformWaitingRequestsAndDelete();
static bool ShouldRetry(const GoogleServiceAuthError& error);
- int64 ComputeExponentialBackOffMilliseconds(int retry_num);
+ int64_t ComputeExponentialBackOffMilliseconds(int retry_num);
// |oauth2_token_service_| remains valid for the life of this Fetcher, since
// this Fetcher is destructed in the dtor of the OAuth2TokenService or is
@@ -304,10 +307,10 @@ void OAuth2TokenService::Fetcher::OnGetTokenFailure(
// Returns an exponential backoff in milliseconds including randomness less than
// 1000 ms when retrying fetching an OAuth2 access token.
-int64 OAuth2TokenService::Fetcher::ComputeExponentialBackOffMilliseconds(
+int64_t OAuth2TokenService::Fetcher::ComputeExponentialBackOffMilliseconds(
int retry_num) {
DCHECK(retry_num < max_fetch_retry_num_);
- int64 exponential_backoff_in_seconds = 1 << retry_num;
+ int64_t exponential_backoff_in_seconds = 1 << retry_num;
// Returns a backoff with randomness < 1000ms
return (exponential_backoff_in_seconds + base::RandDouble()) * 1000;
}