Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(637)

Side by Side Diff: mojo/public/cpp/bindings/lib/associated_interface_ptr.cc

Issue 2772983002: Make sure channel-associated interface pointers are always safe to call. (Closed)
Patch Set: . Created 3 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
(Empty)
1 // Copyright 2017 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #include "mojo/public/cpp/bindings/associated_interface_ptr.h"
6
7 namespace mojo {
8
9 void GetIsolatedInterface(ScopedInterfaceEndpointHandle handle) {
10 MessagePipe pipe;
11 scoped_refptr<internal::MultiplexRouter> router =
12 new internal::MultiplexRouter(std::move(pipe.handle0),
13 internal::MultiplexRouter::MULTI_INTERFACE,
14 false, base::ThreadTaskRunnerHandle::Get());
15 router->AssociateInterface(std::move(handle));
16 }
17
18 } // namespace mojo
OLDNEW
« no previous file with comments | « mojo/public/cpp/bindings/associated_interface_ptr.h ('k') | mojo/public/cpp/bindings/tests/associated_interface_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698