HomeFreeBSD

Reduce duplication in __mac_*_(file|link)(2) implementation.

Description

Reduce duplication in __mac_*_(file|link)(2) implementation.

Reviewed by: rwatson
Obtained from: CheriBSD
Sponsored by: DARPA, AFRL
Differential Revision: https://reviews.freebsd.org/D14175