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

Side by Side Diff: ppapi/native_client/src/trusted/plugin/srpc_client.cc

Issue 11783112: Remove the NaCl SRPC proxy from Chrome. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 11 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 | Annotate | Revision Log
« no previous file with comments | « ppapi/native_client/src/trusted/plugin/srpc_client.h ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (c) 2012 The Chromium Authors. All rights reserved. 2 * Copyright (c) 2012 The Chromium Authors. All rights reserved.
3 * Use of this source code is governed by a BSD-style license that can be 3 * Use of this source code is governed by a BSD-style license that can be
4 * found in the LICENSE file. 4 * found in the LICENSE file.
5 */ 5 */
6 6
7 #include "native_client/src/trusted/plugin/srpc_client.h" 7 #include "native_client/src/trusted/plugin/srpc_client.h"
8 8
9 #include <string.h> 9 #include <string.h>
10 10
(...skipping 86 matching lines...) Expand 10 before | Expand all | Expand 10 after
97 NaClSrpcDtor(&srpc_channel_); 97 NaClSrpcDtor(&srpc_channel_);
98 } 98 }
99 for (Methods::iterator iter = methods_.begin(); 99 for (Methods::iterator iter = methods_.begin();
100 iter != methods_.end(); 100 iter != methods_.end();
101 ++iter) { 101 ++iter) {
102 delete iter->second; 102 delete iter->second;
103 } 103 }
104 PLUGIN_PRINTF(("SrpcClient::~SrpcClient (return)\n")); 104 PLUGIN_PRINTF(("SrpcClient::~SrpcClient (return)\n"));
105 } 105 }
106 106
107 bool SrpcClient::StartJSObjectProxy(Plugin* plugin, ErrorInfo *error_info) {
108 // Start up PPAPI interaction if the plugin determines that the
109 // requisite methods are exported.
110 return plugin->StartProxiedExecution(&srpc_channel_, error_info);
111 }
112
113 void SrpcClient::GetMethods() { 107 void SrpcClient::GetMethods() {
114 PLUGIN_PRINTF(("SrpcClient::GetMethods (this=%p)\n", 108 PLUGIN_PRINTF(("SrpcClient::GetMethods (this=%p)\n",
115 static_cast<void*>(this))); 109 static_cast<void*>(this)));
116 if (NULL == srpc_channel_.client) { 110 if (NULL == srpc_channel_.client) {
117 return; 111 return;
118 } 112 }
119 uint32_t method_count = NaClSrpcServiceMethodCount(srpc_channel_.client); 113 uint32_t method_count = NaClSrpcServiceMethodCount(srpc_channel_.client);
120 // Intern the methods into a mapping from identifiers to MethodInfo. 114 // Intern the methods into a mapping from identifiers to MethodInfo.
121 for (uint32_t i = 0; i < method_count; ++i) { 115 for (uint32_t i = 0; i < method_count; ++i) {
122 int retval; 116 int retval;
(...skipping 73 matching lines...) Expand 10 before | Expand all | Expand 10 after
196 PLUGIN_PRINTF(("SrpcClient::Invoke (return 1)\n")); 190 PLUGIN_PRINTF(("SrpcClient::Invoke (return 1)\n"));
197 return true; 191 return true;
198 } 192 }
199 193
200 void SrpcClient::AttachService(NaClSrpcService* service, void* instance_data) { 194 void SrpcClient::AttachService(NaClSrpcService* service, void* instance_data) {
201 srpc_channel_.server = service; 195 srpc_channel_.server = service;
202 srpc_channel_.server_instance_data = instance_data; 196 srpc_channel_.server_instance_data = instance_data;
203 } 197 }
204 198
205 } // namespace plugin 199 } // namespace plugin
OLDNEW
« no previous file with comments | « ppapi/native_client/src/trusted/plugin/srpc_client.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698