Browse Source

jail: fix build on platforms without seccomp support

buildbots started failing due to -Werror=missing-declarations
for 'parseOCIlinuxseccomp' and 'applyOCIlinuxseccomp'.
Make sure functions were declared before defining comptibility stubs
for non-seccomp platforms.

Fixes: ea7a790 ("jail: add support for running OCI bundle")
Signed-off-by: Daniel Golle <daniel@makrotopia.org>
Daniel Golle 3 years ago
parent
commit
f1aa7a79d8
1 changed files with 1 additions and 3 deletions
  1. 1 3
      jail/seccomp-oci.h

+ 1 - 3
jail/seccomp-oci.h

@@ -15,12 +15,10 @@
 
 #include <linux/filter.h>
 
-#ifdef SECCOMP_SUPPORT
 struct sock_fprog *parseOCIlinuxseccomp(struct blob_attr *msg);
 int applyOCIlinuxseccomp(struct sock_fprog *prog);
-#else
-
 
+#ifndef SECCOMP_SUPPORT
 struct sock_fprog *parseOCIlinuxseccomp(struct blob_attr *msg) {
 	return NULL;
 }