HomeFreeBSD

xz: Improve compatibility with systems without capability mode support

Description

xz: Improve compatibility with systems without capability mode support

When the kernel is built without capability mode support, or when
using an emulator like qemu-user-static that does not translate
system calls, these calls will return a negative number and set
the errno to ENOSYS. However, this error does not indicate a
real programming or runtime error and is generally ignored by
base system applications built with capability mode sandboxing.

Match this behavior by making xz(1) to ignore ENOSYS errors
when calling capability mode system calls too.

PR: 269185
Reported by: Dan Kotowski
Approved by: re (cperciva)

(cherry picked from commit c237c10a2346dec422233db05b2012afd45363fa)
(cherry picked from commit 0cc2deb476bec103ad7c8dbeb650aa2937d6a0da)

Details

Provenance
delphijAuthored on Mar 5 2023, 9:40 AM
Parents
rG96064e0924d8: amd64: Avoid copying td_frame from kernel procs
Branches
Unknown
Tags
Unknown