aboutsummaryrefslogtreecommitdiff
path: root/src/xz
diff options
context:
space:
mode:
authorJia Tan <jiat0218@gmail.com>2023-03-08 23:08:46 +0800
committerJia Tan <jiat0218@gmail.com>2023-03-08 23:22:11 +0800
commit916448d624aaf55cef0fc3e53754affb8c4f309d (patch)
treedf62eb78c6ddab77cc41a6b91b9e635482254f84 /src/xz
parentxz: Fix -Wunused-label in io_sandbox_enter(). (diff)
downloadxz-916448d624aaf55cef0fc3e53754affb8c4f309d.tar.xz
Revert: "Add warning if Capsicum sandbox system calls are unsupported."
The warning causes the exit status to be 2, so this will cause problems for many scripted use cases for xz. The sandbox usage is already very limited already, so silently disabling this allows it to be more usable.
Diffstat (limited to 'src/xz')
-rw-r--r--src/xz/file_io.c10
1 files changed, 4 insertions, 6 deletions
diff --git a/src/xz/file_io.c b/src/xz/file_io.c
index bc4f933d..37710428 100644
--- a/src/xz/file_io.c
+++ b/src/xz/file_io.c
@@ -233,13 +233,11 @@ io_sandbox_enter(int src_fd)
#ifdef HAVE_CAPSICUM
capsicum_error:
- // Even though it is undocumented, if a kernel is configured without
- // capability mode support or used in an emulator that does not
- // implement the capability system calls, then the capsicum system
- // calls will fail and set errno to ENOSYS.
+ // If a kernel is configured without capability mode support or
+ // used in an emulator that does not implement the capability
+ // system calls, then the capsicum system calls will fail and set
+ // errno to ENOSYS.
if (errno == ENOSYS) {
- message_warning(_("%s: Cannot enable the sandbox"),
- strerror(errno));
sandbox_allowed = false;
return;
}