aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichael Kerrisk <mtk.manpages@gmail.com>2021-02-06 10:26:43 +0100
committerMichael Kerrisk <mtk.manpages@gmail.com>2021-02-06 10:26:43 +0100
commitbdd65639ba37af073e97dffbd74c1dbdec70ef35 (patch)
treee27e0613eda6e81a39782e6fdf44cfab93eb811b
parentc7c869e66dada19aadc1845bbe28aa617bb63716 (diff)
downloadman-pages-bdd65639ba37af073e97dffbd74c1dbdec70ef35.tar.gz
setbuf.3: POSIX doesn't require to errno to be unchanged after successful setbuf()
See https://www.austingroupbugs.net/view.php?id=397#c799 Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
-rw-r--r--man3/setbuf.315
1 files changed, 15 insertions, 0 deletions
diff --git a/man3/setbuf.3 b/man3/setbuf.3
index b79ddfd88b..ccfeb83ba4 100644
--- a/man3/setbuf.3
+++ b/man3/setbuf.3
@@ -188,6 +188,21 @@ The
and
.BR setvbuf ()
functions conform to C89 and C99.
+.SH NOTES
+POSIX notes
+.\" https://www.austingroupbugs.net/view.php?id=397#c799
+.\" 0000397: setbuf and errno
+that the value of
+.I errno
+is unspecified after a call to
+.BR setbuf ()
+and further notes that, since the value of
+.I errno
+is not required to be unchanged after a successful call to
+.BR setbuf (),
+applications should instead use
+.BR setvbuf ()
+in order to detect errors.
.SH BUGS
.\" The
.\" .BR setbuffer ()