diff options
author | hidehiko@chromium.org <hidehiko@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2014-03-18 20:49:53 +0000 |
---|---|---|
committer | hidehiko@chromium.org <hidehiko@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2014-03-18 20:49:53 +0000 |
commit | 3e99f1afa25a9af7efb3d2a838fed79d520f1dbb (patch) | |
tree | bf5e30febbe9b719e2e662cd1063c0eb229b5c7b /ppapi | |
parent | 7ae1aeb8fdfcf632d00fe4fcbc797431b73da5ec (diff) | |
download | chromium_src-3e99f1afa25a9af7efb3d2a838fed79d520f1dbb.zip chromium_src-3e99f1afa25a9af7efb3d2a838fed79d520f1dbb.tar.gz chromium_src-3e99f1afa25a9af7efb3d2a838fed79d520f1dbb.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
Review URL: https://codereview.chromium.org/189553005
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@257743 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); |