From 77ebcc05eac2658a68b447e654cfdf7ff3e703b8 Mon Sep 17 00:00:00 2001 From: Mariusz Zaborski Date: Fri, 30 Nov 2018 19:27:14 +0000 Subject: [PATCH] libcasper: do not fail if Capsicum is not avilable Casper service can be also used on the kernels without Capsicum support. Reported by: sbruno Tested by: sbruno --- lib/libcasper/services/cap_fileargs/cap_fileargs.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/libcasper/services/cap_fileargs/cap_fileargs.c b/lib/libcasper/services/cap_fileargs/cap_fileargs.c index 0d9144231be6..fbaa8b52453e 100644 --- a/lib/libcasper/services/cap_fileargs/cap_fileargs.c +++ b/lib/libcasper/services/cap_fileargs/cap_fileargs.c @@ -363,7 +363,7 @@ open_file(const char *name) return (-1); if (caprightsp != NULL) { - if (cap_rights_limit(fd, caprightsp) < 0) { + if (cap_rights_limit(fd, caprightsp) < 0 && errno != ENOSYS) { serrno = errno; close(fd); errno = serrno;