aboutsummaryrefslogtreecommitdiff
path: root/lib/libc/sys/link.2
diff options
context:
space:
mode:
authorKonstantin Belousov <kib@FreeBSD.org>2018-10-25 22:16:34 +0000
committerKonstantin Belousov <kib@FreeBSD.org>2018-10-25 22:16:34 +0000
commit4f77f4888465e376b93ae660ae8f19b6aeebecbe (patch)
tree4bfdb7fc4aed141758cfd1ffd7a1180d3e1cfc5a /lib/libc/sys/link.2
parent2b2135b8b55637077a8c6b1a9a491facb5f0471f (diff)
Notes
Diffstat (limited to 'lib/libc/sys/link.2')
-rw-r--r--lib/libc/sys/link.215
1 files changed, 14 insertions, 1 deletions
diff --git a/lib/libc/sys/link.2 b/lib/libc/sys/link.2
index bb238447e5dbd..057f2aeccd522 100644
--- a/lib/libc/sys/link.2
+++ b/lib/libc/sys/link.2
@@ -28,7 +28,7 @@
.\" @(#)link.2 8.3 (Berkeley) 1/12/94
.\" $FreeBSD$
.\"
-.Dd December 1, 2017
+.Dd October 20, 2018
.Dt LINK 2
.Os
.Sh NAME
@@ -115,6 +115,8 @@ If
.Fa name1
names a symbolic link, a new link for the target of the symbolic link is
created.
+.It Dv AT_BENEATH
+Only allow to link to a file which is beneath of the starting directory.
.El
.Pp
If
@@ -257,6 +259,17 @@ or
respectively, is neither
.Dv AT_FDCWD
nor a file descriptor associated with a directory.
+.It Bq Er ENOTCAPABLE
+The
+.Dv AT_BENEATH
+flag was specified but
+.Fa name1
+is not strictly relative to the starting directory.
+For example,
+.Fa name1
+is absolute or includes a ".." component that escapes the starting directory.
+.Dv AT_BENEATH
+flag was specified.
.El
.Sh SEE ALSO
.Xr chflags 2 ,