HomeFreeBSD

Merge commit 4a39d0890894 from llvm-project (by Mark Johnston):

Description

Merge commit 4a39d0890894 from llvm-project (by Mark Johnston):

[libc++] Fix filesystem::remove_all() on FreeBSD (#79540)

remove_all_impl() opens the target path with O_NOFOLLOW, which fails if
the target is a symbolic link. On FreeBSD, rather than returning ELOOP,
openat() returns EMLINK. This is unlikely to change for compatibility
reasons, see https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=214633 .

Thus, check for EMLINK as well.

Reported by: markj
PR: 276632
MFC after: 3 days

(cherry picked from commit ee14a9725d73150e89367550206803fe36ae3089)

Details

Provenance
dimAuthored on Jan 29 2024, 5:26 PM
Parents
rG94ddf40c0f5d: tcp_wrappers: silence a few warnings
Branches
Unknown
Tags
Unknown