aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichael Kerrisk <mtk.manpages@gmail.com>2016-08-20 14:59:45 +1200
committerMichael Kerrisk <mtk.manpages@gmail.com>2016-08-20 15:02:06 +1200
commite9979dff7cd21490424b9fb20c22ccd3a9c5f5ca (patch)
tree63202f968170b33bce6340f164a96b6f6248b859
parent1a0dff18b26e51464411047a01914f0e5b787b93 (diff)
downloadman-pages-e9979dff7cd21490424b9fb20c22ccd3a9c5f5ca.tar.gz
readlink.2: Emphasize that truncation of returned buffer generates no error
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
-rw-r--r--man2/readlink.25
1 files changed, 4 insertions, 1 deletions
diff --git a/man2/readlink.2 b/man2/readlink.2
index a186dab357..c64c630f6a 100644
--- a/man2/readlink.2
+++ b/man2/readlink.2
@@ -95,7 +95,7 @@ which has size
.BR readlink ()
does not append a null byte to
.IR buf .
-It will truncate the contents (to a length of
+It will (silently) truncate the contents (to a length of
.I bufsiz
characters), in case the buffer is too small to hold all of the contents.
.SS readlinkat()
@@ -154,6 +154,9 @@ for an explanation of the need for
.SH RETURN VALUE
On success, these calls return the number of bytes placed in
.IR buf .
+(If the returned value equals
+.IR busiz ,
+then truncation may have occurred.)
On error, \-1 is returned and
.I errno
is set to indicate the error.