From: Nick Mathewson Date: Tue, 27 May 2014 19:08:10 +0000 (-0400) Subject: Log the errno value if seccomp_load() fails. X-Git-Tag: tor-0.2.5.5-alpha~38^2 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=f0945ac270d08da146b415513fc68c7782f071be;p=thirdparty%2Ftor.git Log the errno value if seccomp_load() fails. (This is how I found out I was trying to test with a kernel too old for seccomp. I think.) --- diff --git a/src/common/sandbox.c b/src/common/sandbox.c index e34268cdad..7586c0cb38 100644 --- a/src/common/sandbox.c +++ b/src/common/sandbox.c @@ -1470,7 +1470,8 @@ install_syscall_filter(sandbox_cfg_t* cfg) // loading the seccomp2 filter if ((rc = seccomp_load(ctx))) { - log_err(LD_BUG, "(Sandbox) failed to load!"); + log_err(LD_BUG, "(Sandbox) failed to load: %d (%s)!", rc, + strerror(-rc)); goto end; }