Index: mojo/application/public/cpp/lib/application_impl.cc |
diff --git a/mojo/application/public/cpp/lib/application_impl.cc b/mojo/application/public/cpp/lib/application_impl.cc |
index 3f98a15caf093c9b1b3dafbea42ee90116330462..82fa7d88effffd3afa0ff96d7fa764771c3ed6af 100644 |
--- a/mojo/application/public/cpp/lib/application_impl.cc |
+++ b/mojo/application/public/cpp/lib/application_impl.cc |
@@ -27,9 +27,11 @@ void DefaultTerminationClosure() { |
} // namespace |
ApplicationImpl::ConnectParams::ConnectParams(const std::string& url) |
- : request_(URLRequest::From(url)) {} |
+ : ConnectParams(URLRequest::From(url)) {} |
ApplicationImpl::ConnectParams::ConnectParams(URLRequestPtr request) |
- : request_(request.Pass()) {} |
+ : request_(request.Pass()), filter_(CapabilityFilter::New()) { |
+ filter_->filter.mark_non_null(); |
+} |
ApplicationImpl::ConnectParams::~ConnectParams() {} |
ApplicationImpl::ApplicationImpl(ApplicationDelegate* delegate, |
@@ -55,6 +57,7 @@ ApplicationImpl::~ApplicationImpl() { |
scoped_ptr<ApplicationConnection> ApplicationImpl::ConnectToApplication( |
const std::string& url) { |
ConnectParams params(url); |
+ params.set_filter(CreatePermissiveCapabilityFilter()); |
return ConnectToApplication(¶ms); |
} |
@@ -167,4 +170,12 @@ void ApplicationImpl::UnbindConnections( |
shell->Bind(shell_.PassInterface()); |
} |
+CapabilityFilterPtr CreatePermissiveCapabilityFilter() { |
+ CapabilityFilterPtr filter(CapabilityFilter::New()); |
+ Array<String> all_interfaces; |
+ all_interfaces.push_back("*"); |
+ filter->filter.insert("*", all_interfaces.Pass()); |
+ return filter.Pass(); |
+} |
+ |
} // namespace mojo |