Chromium Code Reviews| Index: sandbox/linux/seccomp-bpf/sandbox_bpf_unittest.cc |
| diff --git a/sandbox/linux/seccomp-bpf/sandbox_bpf_unittest.cc b/sandbox/linux/seccomp-bpf/sandbox_bpf_unittest.cc |
| index 95fcbc6b5eb800906fe6e2ef319066825b48b5b5..65ec4ce5a602ee1f034300a31435d58751f92c04 100644 |
| --- a/sandbox/linux/seccomp-bpf/sandbox_bpf_unittest.cc |
| +++ b/sandbox/linux/seccomp-bpf/sandbox_bpf_unittest.cc |
| @@ -13,6 +13,7 @@ |
| #include <sys/types.h> |
| #include <sys/utsname.h> |
| #include <unistd.h> |
| +#include <sys/socket.h> |
| #if defined(ANDROID) |
| // Work-around for buggy headers in Android's NDK |
| @@ -662,7 +663,7 @@ BPF_TEST_C(SandboxBPF, SigBus, RedirectAllSyscallsPolicy) { |
| // more complex uses of signals where our use of the SIGBUS mask is not |
| // 100% transparent. This is expected behavior. |
| int fds[2]; |
| - BPF_ASSERT(pipe(fds) == 0); |
| + BPF_ASSERT(socketpair(AF_UNIX, SOCK_STREAM, 0, fds) == 0); |
|
mdempsky
2014/07/14 18:10:51
Why switch from a pipe to a socket pair?
nedeljko
2014/07/15 15:22:15
In short, there is a problem in using pipe() here
|
| bus_handler_fd_ = fds[1]; |
| struct sigaction sa = {}; |
| sa.sa_sigaction = SigBusHandler; |
| @@ -1990,6 +1991,13 @@ SANDBOX_TEST(SandboxBPF, DISABLE_ON_TSAN(SeccompRetTrace)) { |
| return; |
| #endif |
| +#if defined(__mips__) |
| + // TODO: Figure out how to support specificity of handeling indirect syscalls |
|
mdempsky
2014/07/14 18:10:51
Typo: handling
nedeljko
2014/07/15 15:22:15
Done.
|
| + // in this test and enable it. |
| + printf("This test is currently disabled on MIPS."); |
| + return; |
| +#endif |
| + |
| pid_t pid = fork(); |
| BPF_ASSERT_NE(-1, pid); |
| if (pid == 0) { |