From: Andreas Schwab Date: Sat, 5 Mar 2022 12:44:08 +0000 (+0100) Subject: * lib-src/seccomp-filter.c (main): Use faccessat2 only if defined. X-Git-Tag: emacs-28.0.92~11 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=0090318c61;p=emacs.git * lib-src/seccomp-filter.c (main): Use faccessat2 only if defined. --- diff --git a/lib-src/seccomp-filter.c b/lib-src/seccomp-filter.c index d368cbb46c8..b5158510104 100644 --- a/lib-src/seccomp-filter.c +++ b/lib-src/seccomp-filter.c @@ -240,7 +240,9 @@ main (int argc, char **argv) should be further restricted using mount namespaces. */ RULE (SCMP_ACT_ALLOW, SCMP_SYS (access)); RULE (SCMP_ACT_ALLOW, SCMP_SYS (faccessat)); +#ifdef __NR_faccessat2 RULE (SCMP_ACT_ALLOW, SCMP_SYS (faccessat2)); +#endif RULE (SCMP_ACT_ALLOW, SCMP_SYS (stat)); RULE (SCMP_ACT_ALLOW, SCMP_SYS (stat64)); RULE (SCMP_ACT_ALLOW, SCMP_SYS (lstat));