Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "services/service_manager/public/cpp/interface_registry.h" | 5 #include "services/service_manager/public/cpp/interface_registry.h" |
| 6 | 6 |
| 7 #include <sstream> | 7 #include <sstream> |
| 8 | 8 |
| 9 #include "mojo/public/cpp/bindings/message.h" | 9 #include "mojo/public/cpp/bindings/message.h" |
| 10 #include "services/service_manager/public/cpp/connection.h" | 10 #include "services/service_manager/public/cpp/connection.h" |
| (...skipping 189 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 200 std::move(handle)); | 200 std::move(handle)); |
| 201 } else if (!default_binder_.is_null()) { | 201 } else if (!default_binder_.is_null()) { |
| 202 default_binder_.Run(interface_name, std::move(handle)); | 202 default_binder_.Run(interface_name, std::move(handle)); |
| 203 } else { | 203 } else { |
| 204 std::stringstream ss; | 204 std::stringstream ss; |
| 205 ss << "Failed to locate a binder for interface: " << interface_name | 205 ss << "Failed to locate a binder for interface: " << interface_name |
| 206 << " requested by: " << remote_identity_.name() << " exposed by: " | 206 << " requested by: " << remote_identity_.name() << " exposed by: " |
| 207 << local_identity_.name() << " via InterfaceProviderSpec \"" << name_ | 207 << local_identity_.name() << " via InterfaceProviderSpec \"" << name_ |
| 208 << "\"."; | 208 << "\"."; |
| 209 Serialize(&ss); | 209 Serialize(&ss); |
| 210 LOG(ERROR) << ss.str(); | 210 VLOG(1) << ss.str(); |
|
Ben Goodger (Google)
2016/11/10 14:44:07
We should leave this one as LOG(ERROR). It's impor
| |
| 211 } | 211 } |
| 212 } else { | 212 } else { |
| 213 std::stringstream ss; | 213 std::stringstream ss; |
| 214 ss << "InterfaceProviderSpec \"" << name_ << "\" prevented service: " | 214 ss << "InterfaceProviderSpec \"" << name_ << "\" prevented service: " |
| 215 << remote_identity_.name() << " from binding interface: " | 215 << remote_identity_.name() << " from binding interface: " |
| 216 << interface_name << " exposed by: " << local_identity_.name(); | 216 << interface_name << " exposed by: " << local_identity_.name(); |
| 217 Serialize(&ss); | 217 Serialize(&ss); |
| 218 LOG(ERROR) << ss.str(); | 218 LOG(ERROR) << ss.str(); |
| 219 mojo::ReportBadMessage(ss.str()); | 219 mojo::ReportBadMessage(ss.str()); |
| 220 } | 220 } |
| (...skipping 28 matching lines...) Expand all Loading... | |
| 249 exposed_interfaces_.size() == 1 && exposed_interfaces_.count("*") == 1; | 249 exposed_interfaces_.size() == 1 && exposed_interfaces_.count("*") == 1; |
| 250 } | 250 } |
| 251 | 251 |
| 252 void InterfaceRegistry::OnConnectionError() { | 252 void InterfaceRegistry::OnConnectionError() { |
| 253 std::list<base::Closure> closures = connection_lost_closures_; | 253 std::list<base::Closure> closures = connection_lost_closures_; |
| 254 for (const auto& closure : closures) | 254 for (const auto& closure : closures) |
| 255 closure.Run(); | 255 closure.Run(); |
| 256 } | 256 } |
| 257 | 257 |
| 258 } // namespace service_manager | 258 } // namespace service_manager |
| OLD | NEW |