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

Side by Side Diff: ppapi/native_client/src/shared/ppapi_proxy/plugin_ppb.cc

Issue 8982006: Add GetLiveVars to PPB_Testing_Dev. Fix leaks it uncovered. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Merged Created 9 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 // Implements the untrusted side of the PPB_GetInterface method. 5 // Implements the untrusted side of the PPB_GetInterface method.
6 6
7 #include "native_client/src/shared/ppapi_proxy/plugin_globals.h" 7 #include "native_client/src/shared/ppapi_proxy/plugin_globals.h"
8 #include <stdlib.h> 8 #include <stdlib.h>
9 #include <string.h> 9 #include <string.h>
10 #include "native_client/src/shared/ppapi_proxy/plugin_ppb_audio.h" 10 #include "native_client/src/shared/ppapi_proxy/plugin_ppb_audio.h"
(...skipping 65 matching lines...) Expand 10 before | Expand all | Expand 10 after
76 PluginInputEvent::GetMouseInterface1_0(), true }, 76 PluginInputEvent::GetMouseInterface1_0(), true },
77 { PPB_MOUSE_INPUT_EVENT_INTERFACE_1_1, 77 { PPB_MOUSE_INPUT_EVENT_INTERFACE_1_1,
78 PluginInputEvent::GetMouseInterface1_1(), true }, 78 PluginInputEvent::GetMouseInterface1_1(), true },
79 { PPB_MOUSELOCK_INTERFACE, PluginMouseLock::GetInterface(), true }, 79 { PPB_MOUSELOCK_INTERFACE, PluginMouseLock::GetInterface(), true },
80 { PPB_OPENGLES2_INTERFACE, PluginGraphics3D::GetOpenGLESInterface(), 80 { PPB_OPENGLES2_INTERFACE, PluginGraphics3D::GetOpenGLESInterface(),
81 true }, 81 true },
82 { PPB_PDF_INTERFACE, PluginPDF::GetInterface(), true }, 82 { PPB_PDF_INTERFACE, PluginPDF::GetInterface(), true },
83 { PPB_SCROLLBAR_DEV_INTERFACE, PluginScrollbar::GetInterface(), true }, 83 { PPB_SCROLLBAR_DEV_INTERFACE, PluginScrollbar::GetInterface(), true },
84 { PPB_TCPSOCKET_PRIVATE_INTERFACE, PluginTCPSocketPrivate::GetInterface(), 84 { PPB_TCPSOCKET_PRIVATE_INTERFACE, PluginTCPSocketPrivate::GetInterface(),
85 true }, 85 true },
86 { PPB_TESTING_DEV_INTERFACE_0_7, PluginTesting::GetInterface(), true },
87 { PPB_TESTING_DEV_INTERFACE_0_8, PluginTesting::GetInterface(), true },
88 { PPB_TESTING_DEV_INTERFACE_0_9, PluginTesting::GetInterface(), true }, 86 { PPB_TESTING_DEV_INTERFACE_0_9, PluginTesting::GetInterface(), true },
87 { PPB_TESTING_DEV_INTERFACE, PluginTesting::GetInterface(), true },
89 { PPB_UDPSOCKET_PRIVATE_INTERFACE, PluginUDPSocketPrivate::GetInterface(), 88 { PPB_UDPSOCKET_PRIVATE_INTERFACE, PluginUDPSocketPrivate::GetInterface(),
90 true }, 89 true },
91 { PPB_URLLOADER_INTERFACE, PluginURLLoader::GetInterface(), true }, 90 { PPB_URLLOADER_INTERFACE, PluginURLLoader::GetInterface(), true },
92 { PPB_URLREQUESTINFO_INTERFACE, PluginURLRequestInfo::GetInterface(), true }, 91 { PPB_URLREQUESTINFO_INTERFACE, PluginURLRequestInfo::GetInterface(), true },
93 { PPB_URLRESPONSEINFO_INTERFACE, PluginURLResponseInfo::GetInterface(), 92 { PPB_URLRESPONSEINFO_INTERFACE, PluginURLResponseInfo::GetInterface(),
94 true }, 93 true },
95 { PPB_VAR_INTERFACE, PluginVar::GetInterface(), true }, 94 { PPB_VAR_INTERFACE, PluginVar::GetInterface(), true },
96 { PPB_VAR_INTERFACE_1_0, PluginVar::GetInterface1_0(), true }, 95 { PPB_VAR_INTERFACE_1_0, PluginVar::GetInterface1_0(), true },
97 { PPB_WHEEL_INPUT_EVENT_INTERFACE, PluginInputEvent::GetWheelInterface(), 96 { PPB_WHEEL_INPUT_EVENT_INTERFACE, PluginInputEvent::GetWheelInterface(),
98 true }, 97 true },
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after
135 interface_name, NaClSrpcErrorString(srpc_result)); 134 interface_name, NaClSrpcErrorString(srpc_result));
136 if (srpc_result != NACL_SRPC_RESULT_OK || !browser_exports_interface) { 135 if (srpc_result != NACL_SRPC_RESULT_OK || !browser_exports_interface) {
137 interface_map[index].ppb_interface = NULL; 136 interface_map[index].ppb_interface = NULL;
138 ppb_interface = NULL; 137 ppb_interface = NULL;
139 } 138 }
140 interface_map[index].needs_browser_check = false; 139 interface_map[index].needs_browser_check = false;
141 return ppb_interface; 140 return ppb_interface;
142 } 141 }
143 142
144 } // namespace ppapi_proxy 143 } // namespace ppapi_proxy
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698