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

Unified Diff: content/common/sandbox_seccomp_bpf_linux.cc

Issue 11434097: Fix the sandbox to actually allow __NR_sched_getaffinity under ASan. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 8 years 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/common/sandbox_seccomp_bpf_linux.cc
===================================================================
--- content/common/sandbox_seccomp_bpf_linux.cc (revision 170827)
+++ content/common/sandbox_seccomp_bpf_linux.cc (working copy)
@@ -1237,6 +1237,10 @@
ErrorCode GpuProcessPolicy_x86_64(int sysno, void *) {
switch(sysno) {
case __NR_ioctl:
+#if defined(ADDRESS_SANITIZER)
+ // Allow to call sched_getaffinity under AddressSanitizer.
+ case __NR_sched_getaffinity:
+#endif
return ErrorCode(ErrorCode::ERR_ALLOWED);
case __NR_open:
// Accelerated video decode is enabled by default only on Chrome OS.
@@ -1253,10 +1257,6 @@
// The hook needs dup(), lseek(), and close() to be allowed.
return Sandbox::Trap(GpuOpenSIGSYS_Handler, NULL);
}
-#if defined(ADDRESS_SANITIZER)
- // Allow to call sched_getaffinity under AddressSanitizer.
- case __NR_sched_getaffinity:
-#endif
default:
if (IsEventFd(sysno))
return ErrorCode(ErrorCode::ERR_ALLOWED);
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698