HomeFreeBSD

Fix for 90e2971 that caused some geli commands to return the wrong exit status.

Description

Fix for 90e2971 that caused some geli commands to return the wrong exit status.

The reported problem is that some geli commands exit with a
success status when they should exit with a failed status.

The gctl_error() function is defined differently in the kernel
(in sys/geom/geom_ctl.c) versus in the geom user facilities (in
sbin/geom/misc/subr.c). In the kernel, calling gctl_error() causes
an error return to be set while in the user version it does not.
It was only by a quirk that had been added to the user geom return
processing that I "cleaned up" that the lack of the user implementaion
to set the error return showed up.

This patch adds the missing setting of the error code when calling
the user facility gctl_error().

Reported by: Jenkins
Debugging by: Alan Somers
Debugging by: Cy Schubert
Debugging by: Li-Wen Hsu

Details

Provenance
mckusickAuthored on Jul 29 2022, 6:11 PM
Parents
rGb0f73768220e: LinuxKPI: 802.11 header updates
Branches
Unknown
Tags
Unknown