From 109b2439f01247b5c8a5313c367ec6b11cb46259 Mon Sep 17 00:00:00 2001 From: Corey Bryant Date: Wed, 18 Dec 2013 11:48:11 -0500 Subject: [PATCH] seccomp: exit if seccomp_init() fails This fixes a bug where we weren't exiting if seccomp_init() failed. Signed-off-by: Corey Bryant Acked-by: Eduardo Otubo Acked-by: Paul Moore (cherry picked from commit 2a13f991123fa16841e6d94b02a9cc2c76d91725) Signed-off-by: Michael Roth --- qemu-seccomp.c | 1 + 1 file changed, 1 insertion(+) diff --git a/qemu-seccomp.c b/qemu-seccomp.c index 69cee443af..7c7b4742a6 100644 --- a/qemu-seccomp.c +++ b/qemu-seccomp.c @@ -230,6 +230,7 @@ int seccomp_start(void) ctx = seccomp_init(SCMP_ACT_KILL); if (ctx == NULL) { + rc = -1; goto seccomp_return; }