| Index: content/common/sandbox_init_linux.cc
|
| diff --git a/content/common/sandbox_init_linux.cc b/content/common/sandbox_init_linux.cc
|
| index 25cbf954fc15a961defab1f912db9a1d7c41d692..f352c74d69d80986152c5852348f841dc9037194 100644
|
| --- a/content/common/sandbox_init_linux.cc
|
| +++ b/content/common/sandbox_init_linux.cc
|
| @@ -12,39 +12,4 @@
|
|
|
| namespace content {
|
|
|
| -// TODO(jln): have call sites provide a process / policy type to
|
| -// InitializeSandbox().
|
| -bool InitializeSandbox() {
|
| - bool seccomp_legacy_started = false;
|
| - bool seccomp_bpf_started = false;
|
| - LinuxSandbox* linux_sandbox = LinuxSandbox::GetInstance();
|
| - const std::string process_type =
|
| - CommandLine::ForCurrentProcess()->GetSwitchValueASCII(
|
| - switches::kProcessType);
|
| -
|
| - // No matter what, it's always an error to call InitializeSandbox() after
|
| - // threads have been created.
|
| - if (!linux_sandbox->IsSingleThreaded()) {
|
| - std::string error_message = "InitializeSandbox() called with multiple "
|
| - "threads in process " + process_type;
|
| - // TODO(jln): change this into a CHECK() once we are more comfortable it
|
| - // does not trigger.
|
| - LOG(ERROR) << error_message;
|
| - return false;
|
| - }
|
| -
|
| - // Attempt to limit the future size of the address space of the process.
|
| - linux_sandbox->LimitAddressSpace(process_type);
|
| -
|
| - // First, try to enable seccomp-bpf.
|
| - seccomp_bpf_started = linux_sandbox->StartSeccompBpf(process_type);
|
| -
|
| - // If that fails, try to enable seccomp-legacy.
|
| - if (!seccomp_bpf_started) {
|
| - seccomp_legacy_started = linux_sandbox->StartSeccompLegacy(process_type);
|
| - }
|
| -
|
| - return seccomp_legacy_started || seccomp_bpf_started;
|
| -}
|
| -
|
| } // namespace content
|
|
|