Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(59)

Unified Diff: content/common/seccomp_sandbox.h

Issue 7570002: linux: turn seccomp on by default in debug (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 9 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « content/browser/zygote_main_linux.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/common/seccomp_sandbox.h
diff --git a/content/common/seccomp_sandbox.h b/content/common/seccomp_sandbox.h
index 0eb376483be57331e956aa8ec0678162924f7161..c1c1f8f37a31a0d86e02a2338560907d2bc1f925 100644
--- a/content/common/seccomp_sandbox.h
+++ b/content/common/seccomp_sandbox.h
@@ -29,11 +29,16 @@ static bool SeccompSandboxEnabled() {
// TODO(evan): turn on for release too once we've flushed out all the bugs,
// allowing us to delete this file entirely and just rely on the "disabled"
// switch.
+#ifdef NDEBUG
+ // Off by default; allow turning on with a switch.
return CommandLine::ForCurrentProcess()->HasSwitch(
- switches::kEnableSeccompSandbox) &&
- !CommandLine::ForCurrentProcess()->HasSwitch(
- switches::kDisableSeccompSandbox);
+ switches::kEnableSeccompSandbox);
+#else
+ // On by default; allow turning off with a switch.
+ return !CommandLine::ForCurrentProcess()->HasSwitch(
+ switches::kDisableSeccompSandbox);
+#endif // NDEBUG
}
-#endif
+#endif // SECCOMP_SANDBOX
#endif // CONTENT_COMMON_SECCOMP_SANDBOX_H_
« no previous file with comments | « content/browser/zygote_main_linux.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698