summaryrefslogtreecommitdiffstats
path: root/content/renderer
diff options
context:
space:
mode:
authorjln@chromium.org <jln@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-08-01 06:29:43 +0000
committerjln@chromium.org <jln@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-08-01 06:29:43 +0000
commit9d29124d4a1fa47803ff5b371406c722b7c82507 (patch)
tree5e9e2d264c662fc07c202f361c534475a2b9e5ce /content/renderer
parent998d3505508036a3408b2525f6107e6a1ba61481 (diff)
downloadchromium_src-9d29124d4a1fa47803ff5b371406c722b7c82507.zip
chromium_src-9d29124d4a1fa47803ff5b371406c722b7c82507.tar.gz
chromium_src-9d29124d4a1fa47803ff5b371406c722b7c82507.tar.bz2
Linux: unify seccomp sandbox initialization
We unify seccomp-bpf and seccomp-legacy initialization in the same file. TBR=jamesr@chromium.org Review URL: https://chromiumcodereview.appspot.com/10828102 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@149381 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'content/renderer')
-rw-r--r--content/renderer/renderer_main_platform_delegate_linux.cc14
1 files changed, 3 insertions, 11 deletions
diff --git a/content/renderer/renderer_main_platform_delegate_linux.cc b/content/renderer/renderer_main_platform_delegate_linux.cc
index e1a39bd..990142c 100644
--- a/content/renderer/renderer_main_platform_delegate_linux.cc
+++ b/content/renderer/renderer_main_platform_delegate_linux.cc
@@ -1,11 +1,10 @@
-// Copyright (c) 2011 The Chromium Authors. All rights reserved.
+// Copyright (c) 2012 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#include "content/renderer/renderer_main_platform_delegate.h"
#include "base/command_line.h"
-#include "content/common/seccomp_sandbox.h"
#include "content/public/common/content_switches.h"
#include "content/public/common/sandbox_init.h"
@@ -33,15 +32,8 @@ bool RendererMainPlatformDelegate::EnableSandbox() {
// The setuid sandbox is started in the zygote process: zygote_main_linux.cc
// http://code.google.com/p/chromium/wiki/LinuxSUIDSandbox
//
- // The seccomp sandbox is started in the renderer.
- // http://code.google.com/p/seccompsandbox/
-#if defined(SECCOMP_SANDBOX)
- // N.b. SupportsSeccompSandbox() returns a cached result, as we already
- // called it earlier in the zygote. Thus, it is OK for us to not pass in
- // a file descriptor for "/proc".
- if (SeccompSandboxEnabled() && SupportsSeccompSandbox(-1))
- StartSeccompSandbox();
-#endif
+ // The seccomp sandbox mode 1 (sandbox/linux/seccomp-legacy) and mode 2
+ // (sandbox/linux/seccomp-bpf) are started in InitializeSandbox().
content::InitializeSandbox();
return true;
}