diff options
author | Mike Frysinger <vapier@gentoo.org> | 2015-09-19 02:17:45 -0400 |
---|---|---|
committer | Mike Frysinger <vapier@gentoo.org> | 2015-09-19 02:17:45 -0400 |
commit | 9575f819a56b7bc4cb501fb63185b43084b66bd5 (patch) | |
tree | 0e196e97dde04c1cb1452fa2bc4d5346ddb2a7d6 /security.c | |
parent | security: whitelist the futex syscall (diff) | |
download | pax-utils-9575f819a56b7bc4cb501fb63185b43084b66bd5.tar.gz pax-utils-9575f819a56b7bc4cb501fb63185b43084b66bd5.tar.bz2 pax-utils-9575f819a56b7bc4cb501fb63185b43084b66bd5.zip |
security: fix build on systems w/out si_syscallv1.1.3
Make sure we do not try to use si_syscall when it isn't available.
URL: https://bugs.gentoo.org/560098
Diffstat (limited to 'security.c')
-rw-r--r-- | security.c | 5 |
1 files changed, 4 insertions, 1 deletions
@@ -44,11 +44,14 @@ static int pax_seccomp_rules_add(scmp_filter_ctx ctx, int syscalls[], size_t num static void pax_seccomp_sigal(__unused__ int signo, siginfo_t *info, __unused__ void *context) { +#ifdef si_syscall warn("seccomp violated: syscall %i", info->si_syscall); fflush(stderr); -#ifdef si_syscall warn(" syscall = %s", seccomp_syscall_resolve_num_arch(seccomp_arch_native(), info->si_syscall)); + fflush(stderr); +#else + warn("seccomp violated: syscall unknown (no si_syscall)"); #endif kill(getpid(), SIGSYS); _exit(1); |