diff options
author | Simon South <simon@simonsouth.net> | 2021-11-05 10:10:10 -0400 |
---|---|---|
committer | Simon South <simon@simonsouth.net> | 2021-11-05 10:30:51 -0400 |
commit | 001d880d1082f5d124e10554e2718e407c7e88c6 (patch) | |
tree | 68a5792507af136c7a8277c4eea9601573cafe84 /src/lib/sandbox | |
parent | d59f63f1c40771e80638bac447947e51c07e3ad4 (diff) | |
download | tor-001d880d1082f5d124e10554e2718e407c7e88c6.tar.gz tor-001d880d1082f5d124e10554e2718e407c7e88c6.zip |
sandbox: Allow "statx" syscall on i386 for glibc 2.33
glibc versions 2.33 and newer use the modern "statx" system call in their
implementations of stat() and opendir() for Linux on i386. Prevent failures in
the sandbox unit tests by modifying the sandbox to allow this system call
without restriction on i386 when it is available, and update the test suite to
skip the "sandbox/stat_filename" test in this case as it is certain to fail.
Diffstat (limited to 'src/lib/sandbox')
-rw-r--r-- | src/lib/sandbox/sandbox.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/lib/sandbox/sandbox.c b/src/lib/sandbox/sandbox.c index fb02a345ab..a15f99ad76 100644 --- a/src/lib/sandbox/sandbox.c +++ b/src/lib/sandbox/sandbox.c @@ -252,6 +252,9 @@ static int filter_nopar_gen[] = { SCMP_SYS(sigreturn), #endif SCMP_SYS(stat), +#if defined(__i386__) && defined(__NR_statx) + SCMP_SYS(statx), +#endif SCMP_SYS(uname), SCMP_SYS(wait4), SCMP_SYS(write), |