| Index: components/nacl/browser/nacl_process_host.cc
|
| diff --git a/components/nacl/browser/nacl_process_host.cc b/components/nacl/browser/nacl_process_host.cc
|
| index b16b6d86c1fac28c75b4686fb88c16954a6155ba..b8bb6bde096ad30a31403ccfc218bd64b30ed20a 100644
|
| --- a/components/nacl/browser/nacl_process_host.cc
|
| +++ b/components/nacl/browser/nacl_process_host.cc
|
| @@ -48,10 +48,11 @@
|
| #include "ppapi/host/host_factory.h"
|
| #include "ppapi/host/ppapi_host.h"
|
| #include "ppapi/proxy/ppapi_messages.h"
|
| +#include "ppapi/shared_impl/ppapi_constants.h"
|
| #include "ppapi/shared_impl/ppapi_nacl_plugin_args.h"
|
| -#include "ppapi/shared_impl/ppapi_switches.h"
|
|
|
| #if defined(OS_POSIX)
|
| +
|
| #include <fcntl.h>
|
|
|
| #include "ipc/ipc_channel_posix.h"
|
| @@ -233,6 +234,9 @@ struct NaClProcessHost::NaClInternal {
|
|
|
| // -----------------------------------------------------------------------------
|
|
|
| +unsigned NaClProcessHost::keepalive_throttle_interval_milliseconds_ =
|
| + ppapi::kKeepaliveThrottleIntervalDefaultMilliseconds;
|
| +
|
| NaClProcessHost::NaClProcessHost(const GURL& manifest_url,
|
| int render_view_id,
|
| uint32 permission_bits,
|
| @@ -354,6 +358,12 @@ void NaClProcessHost::EarlyStartup() {
|
| NaClBrowser::GetDelegate()->SetDebugPatterns(nacl_debug_mask);
|
| }
|
|
|
| +// static
|
| +void NaClProcessHost::SetPpapiKeepAliveThrottleForTesting(
|
| + unsigned milliseconds) {
|
| + keepalive_throttle_interval_milliseconds_ = milliseconds;
|
| +}
|
| +
|
| void NaClProcessHost::Launch(
|
| NaClHostMessageFilter* nacl_host_message_filter,
|
| IPC::Message* reply_msg,
|
| @@ -858,10 +868,11 @@ void NaClProcessHost::OnPpapiChannelsCreated(
|
| ppapi::PpapiNaClPluginArgs args;
|
| args.off_the_record = nacl_host_message_filter_->off_the_record();
|
| args.permissions = permissions_;
|
| + args.keepalive_throttle_interval_milliseconds =
|
| + keepalive_throttle_interval_milliseconds_;
|
| CommandLine* cmdline = CommandLine::ForCurrentProcess();
|
| DCHECK(cmdline);
|
| std::string flag_whitelist[] = {
|
| - switches::kPpapiKeepAliveThrottle,
|
| switches::kV,
|
| switches::kVModule,
|
| };
|
|
|