HomeFreeBSD

fstatat(2): handle non-vnode file descriptors for AT_EMPTY_PATH

Description

fstatat(2): handle non-vnode file descriptors for AT_EMPTY_PATH

Set NIRES_EMPTYPATH earlies, to have use of EMPTYPATH recorded even if
we are going to return error. When namei_setup() refused to accept dirfd,
which is not of the vnode type, and indicated by ENOTDIR error return,
fall back to kern_fstat(dirfd).

Reported by: dchagin
Reviewed by: markj
Sponsored by: The FreeBSD Foundation
MFC after: 1 week
Differential revision: https://reviews.freebsd.org/D31530

Details

Provenance
kibAuthored on Aug 13 2021, 5:40 PM
Reviewer
markj
Differential Revision
D31530: fstatat(2): handle non-vnode file descriptors for AT_EMPTY_PATH
Parents
rG6b25b4a73fbe: mgb: update Microchip URLs
Branches
Unknown
Tags
Unknown