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); |