summaryrefslogtreecommitdiffstats
path: root/remoting
diff options
context:
space:
mode:
authorsergeyu@chromium.org <sergeyu@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-04-14 04:36:02 +0000
committersergeyu@chromium.org <sergeyu@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-04-14 04:36:02 +0000
commit45b1d04e99a13b60194a108a3b582268ae56916f (patch)
tree65ed9bedd88e1474e6019ec969f6e5e75a229fe2 /remoting
parent6542a57b3ab7317f5bbf06990ce98bfb259bc7af (diff)
downloadchromium_src-45b1d04e99a13b60194a108a3b582268ae56916f.zip
chromium_src-45b1d04e99a13b60194a108a3b582268ae56916f.tar.gz
chromium_src-45b1d04e99a13b60194a108a3b582268ae56916f.tar.bz2
Call XmppSignalStrategy::SetAuthInfo() on the right thread.
BUG=123384 Review URL: http://codereview.chromium.org/10081025 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@132325 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'remoting')
-rw-r--r--remoting/host/remoting_me2me_host.cc9
1 files changed, 7 insertions, 2 deletions
diff --git a/remoting/host/remoting_me2me_host.cc b/remoting/host/remoting_me2me_host.cc
index ac73694..f380056 100644
--- a/remoting/host/remoting_me2me_host.cc
+++ b/remoting/host/remoting_me2me_host.cc
@@ -148,6 +148,8 @@ class HostProcess : public OAuthClient::Delegate {
// handle it directly, so refresh it asynchronously. A task will be
// posted on the message loop to start watching the NAT policy when
// the access token is available.
+ //
+ // TODO(sergeyu): Move this code to SignalingConnector.
oauth_client_.Start(oauth_refresh_token_, this,
message_loop_.message_loop_proxy());
} else {
@@ -173,8 +175,11 @@ class HostProcess : public OAuthClient::Delegate {
// next time it calls Connect. If not, then this is the initial token
// exchange, so proceed to the next stage of connection.
if (signal_strategy_.get()) {
- signal_strategy_->SetAuthInfo(xmpp_login_, xmpp_auth_token_,
- xmpp_auth_service_);
+ context_->network_message_loop()->PostTask(
+ FROM_HERE, base::Bind(
+ &XmppSignalStrategy::SetAuthInfo,
+ base::Unretained(signal_strategy_.get()),
+ xmpp_login_, xmpp_auth_token_, xmpp_auth_service_));
} else {
StartWatchingNatPolicy();
}