diff options
author | hidehiko@chromium.org <hidehiko@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2014-03-20 05:40:10 +0000 |
---|---|---|
committer | hidehiko@chromium.org <hidehiko@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2014-03-20 05:40:10 +0000 |
commit | 923a2ab58248417ffa52c1291e28eaa0d5ae69ed (patch) | |
tree | 1286d778eb08a2b54fe40abd75c4b9abce88fb94 /ppapi | |
parent | 37be4cfa624362b95a69ca0581518df76435c301 (diff) | |
download | chromium_src-923a2ab58248417ffa52c1291e28eaa0d5ae69ed.zip chromium_src-923a2ab58248417ffa52c1291e28eaa0d5ae69ed.tar.gz chromium_src-923a2ab58248417ffa52c1291e28eaa0d5ae69ed.tar.bz2 |
Add very simple loading test for non-SFI NaCl.
This is the first step to add test cases for non-SFI NaCl.
The testee binary is build by a new target rule introduced by this CL, which is relocatable/libc-free binary. The code has a minimum set of handlers for irt_ppapi, to load the plugin successfully done with communicating hosts (browser/renderer processes).
Along this change, some DCHECK errors are found. So they're fixed, too.
1) AtExitManager is conflicting. In non-SFI mode, AtExitManager is already instantiated in nacl_helper. To avoid the conflicting, skip to create it in plugin_main_irt.cc.
2) Allowed creating Singleton on the plugin's main thread.
3) SRPC may be successfully done, and then NOTREACHED catch it in nacl_listener. It is false alarm, so removed it.
BUG=https://code.google.com/p/nativeclient/issues/detail?id=3734
TEST=run ./browser_tests --gtest_filter=NaCl*NonSFI* locally. Run trybots.
Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=257118
Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=257743
Review URL: https://codereview.chromium.org/189553005
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@258200 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'ppapi')
-rw-r--r-- | ppapi/proxy/plugin_main_irt.cc | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/ppapi/proxy/plugin_main_irt.cc b/ppapi/proxy/plugin_main_irt.cc index a3ea6c1..7182ab0 100644 --- a/ppapi/proxy/plugin_main_irt.cc +++ b/ppapi/proxy/plugin_main_irt.cc @@ -14,7 +14,6 @@ // IPC_MESSAGE_MACROS_LOG_ENABLED so ppapi_messages.h will generate the // ViewMsgLog et al. functions. -#include "base/at_exit.h" #include "base/command_line.h" #include "base/memory/scoped_ptr.h" #include "base/message_loop/message_loop.h" @@ -36,6 +35,7 @@ #include "ppapi/shared_impl/ppb_audio_shared.h" #if defined(__native_client__) +#include "base/at_exit.h" #include "native_client/src/public/chrome_main.h" #include "native_client/src/shared/srpc/nacl_srpc.h" #endif @@ -327,8 +327,12 @@ void PpapiPluginRegisterThreadCreator( } int PpapiPluginMain() { + // For non-SFI mode, the manager is already instantiated in nacl_helper, + // so we don't need to instantiate it here. +#if defined(__native_client__) // Though it isn't referenced here, we must instantiate an AtExitManager. base::AtExitManager exit_manager; +#endif base::MessageLoop loop; #if defined(IPC_MESSAGE_LOG_ENABLED) IPC::Logging::set_log_function_map(&g_log_function_mapping); |