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

Side by Side Diff: ppapi/nacl_irt/manifest_service.cc

Issue 1184523003: attachment broker wip (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Minor comments. Created 5 years, 6 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
« no previous file with comments | « ipc/sync_socket_unittest.cc ('k') | ppapi/nacl_irt/ppapi_dispatcher.cc » ('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 "ppapi/nacl_irt/manifest_service.h" 5 #include "ppapi/nacl_irt/manifest_service.h"
6 6
7 #include "base/single_thread_task_runner.h" 7 #include "base/single_thread_task_runner.h"
8 #include "ipc/ipc_channel_handle.h" 8 #include "ipc/ipc_channel_handle.h"
9 #include "ipc/ipc_channel_proxy.h" 9 #include "ipc/ipc_channel_proxy.h"
10 #include "ipc/ipc_sync_message_filter.h" 10 #include "ipc/ipc_sync_message_filter.h"
(...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after
62 base::WaitableEvent connected_event_; 62 base::WaitableEvent connected_event_;
63 63
64 DISALLOW_COPY_AND_ASSIGN(ManifestMessageFilter); 64 DISALLOW_COPY_AND_ASSIGN(ManifestMessageFilter);
65 }; 65 };
66 66
67 ManifestService::ManifestService( 67 ManifestService::ManifestService(
68 const IPC::ChannelHandle& handle, 68 const IPC::ChannelHandle& handle,
69 scoped_refptr<base::SingleThreadTaskRunner> io_task_runner, 69 scoped_refptr<base::SingleThreadTaskRunner> io_task_runner,
70 base::WaitableEvent* shutdown_event) { 70 base::WaitableEvent* shutdown_event) {
71 filter_ = new ManifestMessageFilter(shutdown_event); 71 filter_ = new ManifestMessageFilter(shutdown_event);
72 // TODO(erikchen): fixme
72 channel_ = IPC::ChannelProxy::Create(handle, IPC::Channel::MODE_SERVER, 73 channel_ = IPC::ChannelProxy::Create(handle, IPC::Channel::MODE_SERVER,
73 NULL, // Listener 74 NULL, // Listener
74 io_task_runner.get()); 75 io_task_runner.get(), nullptr);
75 channel_->AddFilter(filter_.get()); 76 channel_->AddFilter(filter_.get());
76 } 77 }
77 78
78 ManifestService::~ManifestService() { 79 ManifestService::~ManifestService() {
79 } 80 }
80 81
81 void ManifestService::StartupInitializationComplete() { 82 void ManifestService::StartupInitializationComplete() {
82 filter_->Send(new PpapiHostMsg_StartupInitializationComplete); 83 filter_->Send(new PpapiHostMsg_StartupInitializationComplete);
83 } 84 }
84 85
(...skipping 77 matching lines...) Expand 10 before | Expand all | Expand 10 after
162 163
163 ManifestService* manifest_service = GetManifestService(); 164 ManifestService* manifest_service = GetManifestService();
164 if (manifest_service == NULL || 165 if (manifest_service == NULL ||
165 !manifest_service->OpenResource(file, fd)) { 166 !manifest_service->OpenResource(file, fd)) {
166 return NACL_ABI_EIO; 167 return NACL_ABI_EIO;
167 } 168 }
168 return (*fd == -1) ? NACL_ABI_ENOENT : 0; 169 return (*fd == -1) ? NACL_ABI_ENOENT : 0;
169 } 170 }
170 171
171 } // namespace ppapi 172 } // namespace ppapi
OLDNEW
« no previous file with comments | « ipc/sync_socket_unittest.cc ('k') | ppapi/nacl_irt/ppapi_dispatcher.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698