Chromium Code Reviews| Index: remoting/host/it2me/it2me_native_messaging_host.cc |
| diff --git a/remoting/host/it2me/it2me_native_messaging_host.cc b/remoting/host/it2me/it2me_native_messaging_host.cc |
| index f65cb524dd3b7f950bfb2411fd708a044f374a77..a47119736d7d4ea61e9b5c6f0935767919e65878 100644 |
| --- a/remoting/host/it2me/it2me_native_messaging_host.cc |
| +++ b/remoting/host/it2me/it2me_native_messaging_host.cc |
| @@ -54,8 +54,8 @@ It2MeNativeMessagingHost::It2MeNativeMessagingHost( |
| host_context_.reset(ChromotingHostContext::Create(task_runner).release()); |
| - ServiceUrls* service_urls = ServiceUrls::GetInstance(); |
| - bool xmpp_server_valid = |
| + const ServiceUrls* const service_urls = ServiceUrls::GetInstance(); |
|
nadav
2014/02/19 16:21:53
That's probably too many consts.
Unless you really
weitao
2014/02/19 17:52:18
Done.
|
| + const bool xmpp_server_valid = |
| net::ParseHostAndPort(service_urls->xmpp_server_address(), |
| &xmpp_server_config_.host, |
| &xmpp_server_config_.port); |
| @@ -74,7 +74,7 @@ It2MeNativeMessagingHost::~It2MeNativeMessagingHost() { |
| } |
| } |
| -void It2MeNativeMessagingHost::Start(const base::Closure& quit_closure) { |
| +void It2MeNativeMessagingHost::Start(const base::Closure& quit_closure) const { |
| DCHECK(task_runner()->BelongsToCurrentThread()); |
| channel_->Start( |
| @@ -115,7 +115,7 @@ void It2MeNativeMessagingHost::ProcessMessage( |
| void It2MeNativeMessagingHost::ProcessHello( |
| const base::DictionaryValue& message, |
| - scoped_ptr<base::DictionaryValue> response) { |
| + scoped_ptr<base::DictionaryValue> response) const { |
| DCHECK(task_runner()->BelongsToCurrentThread()); |
| response->SetString("version", STRINGIZE(VERSION)); |
| @@ -215,7 +215,7 @@ void It2MeNativeMessagingHost::ProcessDisconnect( |
| void It2MeNativeMessagingHost::SendErrorAndExit( |
| scoped_ptr<base::DictionaryValue> response, |
| - const std::string& description) { |
| + const std::string& description) const { |
| DCHECK(task_runner()->BelongsToCurrentThread()); |
| LOG(ERROR) << description; |
| @@ -289,7 +289,8 @@ void It2MeNativeMessagingHost::OnClientAuthenticated( |
| client_username_ = client_username; |
| } |
| -scoped_refptr<AutoThreadTaskRunner> It2MeNativeMessagingHost::task_runner() { |
| +scoped_refptr<AutoThreadTaskRunner> |
| +It2MeNativeMessagingHost::task_runner() const { |
| return host_context_->ui_task_runner(); |
| } |
| @@ -300,3 +301,4 @@ std::string It2MeNativeMessagingHost::HostStateToString( |
| } |
| } // namespace remoting |
| + |