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

Side by Side Diff: mojo/edk/embedder/embedder.cc

Issue 799113004: Update mojo sdk to rev 59145288bae55b0fce4276b017df6a1117bcf00f (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: add mojo's ply to checklicenses whitelist Created 6 years 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
« no previous file with comments | « mojo/converters/surfaces/tests/BUILD.gn ('k') | mojo/edk/js/tests/sample_service_tests.js » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 "mojo/edk/embedder/embedder.h" 5 #include "mojo/edk/embedder/embedder.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/location.h" 8 #include "base/location.h"
9 #include "base/logging.h" 9 #include "base/logging.h"
10 #include "base/memory/scoped_ptr.h" 10 #include "base/memory/scoped_ptr.h"
(...skipping 26 matching lines...) Expand all
37 scoped_refptr<system::Channel> channel = 37 scoped_refptr<system::Channel> channel =
38 new system::Channel(internal::g_core->platform_support()); 38 new system::Channel(internal::g_core->platform_support());
39 if (!channel->Init(system::RawChannel::Create(platform_handle.Pass()))) { 39 if (!channel->Init(system::RawChannel::Create(platform_handle.Pass()))) {
40 // This is very unusual (e.g., maybe |platform_handle| was invalid or we 40 // This is very unusual (e.g., maybe |platform_handle| was invalid or we
41 // reached some system resource limit). 41 // reached some system resource limit).
42 LOG(ERROR) << "Channel::Init() failed"; 42 LOG(ERROR) << "Channel::Init() failed";
43 // Return null, since |Shutdown()| shouldn't be called in this case. 43 // Return null, since |Shutdown()| shouldn't be called in this case.
44 return 0; 44 return 0;
45 } 45 }
46 46
47 channel->AttachAndRunEndpoint(channel_endpoint, true); 47 channel->SetBootstrapEndpoint(channel_endpoint);
48 48
49 DCHECK(internal::g_channel_manager); 49 DCHECK(internal::g_channel_manager);
50 return internal::g_channel_manager->AddChannel( 50 return internal::g_channel_manager->AddChannel(
51 channel, base::MessageLoopProxy::current()); 51 channel, base::MessageLoopProxy::current());
52 } 52 }
53 53
54 // Helper for |CreateChannel()|. Called on the channel creation thread. 54 // Helper for |CreateChannel()|. Called on the channel creation thread.
55 void CreateChannelHelper( 55 void CreateChannelHelper(
56 ScopedPlatformHandle platform_handle, 56 ScopedPlatformHandle platform_handle,
57 scoped_ptr<ChannelInfo> channel_info, 57 scoped_ptr<ChannelInfo> channel_info,
(...skipping 145 matching lines...) Expand 10 before | Expand all | Expand 10 after
203 203
204 *platform_handle = 204 *platform_handle =
205 static_cast<system::PlatformHandleDispatcher*>(dispatcher.get()) 205 static_cast<system::PlatformHandleDispatcher*>(dispatcher.get())
206 ->PassPlatformHandle() 206 ->PassPlatformHandle()
207 .Pass(); 207 .Pass();
208 return MOJO_RESULT_OK; 208 return MOJO_RESULT_OK;
209 } 209 }
210 210
211 } // namespace embedder 211 } // namespace embedder
212 } // namespace mojo 212 } // namespace mojo
OLDNEW
« no previous file with comments | « mojo/converters/surfaces/tests/BUILD.gn ('k') | mojo/edk/js/tests/sample_service_tests.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698