summaryrefslogtreecommitdiffstats
path: root/chrome/browser/net/gaia
diff options
context:
space:
mode:
authorerg@chromium.org <erg@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-08-02 22:20:14 +0000
committererg@chromium.org <erg@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-08-02 22:20:14 +0000
commitbd748fbe6267f251d1e787c33f0697404d31e85b (patch)
tree29b82a67f1ed1e6059483bda87661ab189fb61df /chrome/browser/net/gaia
parent5483ee534ea73999eeec2da5ea178899b150435f (diff)
downloadchromium_src-bd748fbe6267f251d1e787c33f0697404d31e85b.zip
chromium_src-bd748fbe6267f251d1e787c33f0697404d31e85b.tar.gz
chromium_src-bd748fbe6267f251d1e787c33f0697404d31e85b.tar.bz2
Profile: Make NOTIFICATION_TOKEN_UPDATE profile specific for our multiprofile world.
This should keep TokenServices from different profiles from bleeding into each other. BUG=87457,90921 TEST=none Review URL: http://codereview.chromium.org/7537040 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@95171 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/net/gaia')
-rw-r--r--chrome/browser/net/gaia/token_service.cc5
1 files changed, 3 insertions, 2 deletions
diff --git a/chrome/browser/net/gaia/token_service.cc b/chrome/browser/net/gaia/token_service.cc
index 6601fe1..35ec183 100644
--- a/chrome/browser/net/gaia/token_service.cc
+++ b/chrome/browser/net/gaia/token_service.cc
@@ -13,6 +13,7 @@
#include "chrome/common/net/gaia/gaia_constants.h"
#include "content/browser/browser_thread.h"
#include "content/common/notification_service.h"
+#include "content/common/notification_source.h"
#include "net/url_request/url_request_context_getter.h"
// Unfortunately kNumServices must be defined in the .h.
@@ -68,7 +69,7 @@ void TokenService::Initialize(const char* const source,
registrar_.Add(this,
chrome::NOTIFICATION_TOKEN_UPDATED,
- NotificationService::AllSources());
+ Source<Profile>(profile));
}
void TokenService::ResetCredentialsInMemory() {
@@ -281,7 +282,7 @@ void TokenService::LoadTokensIntoMemory(
void TokenService::Observe(int type,
const NotificationSource& source,
const NotificationDetails& details) {
- DCHECK(type == chrome::NOTIFICATION_TOKEN_UPDATED);
+ DCHECK_EQ(type, chrome::NOTIFICATION_TOKEN_UPDATED);
TokenAvailableDetails* tok_details =
Details<TokenAvailableDetails>(details).ptr();
OnIssueAuthTokenSuccess(tok_details->service(), tok_details->token());