Explorar o código

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.)
Nick Mathewson %!s(int64=11) %!d(string=hai) anos
pai
achega
f0945ac270
Modificáronse 1 ficheiros con 2 adicións e 1 borrados
  1. 2 1
      src/common/sandbox.c

+ 2 - 1
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;
   }