setbuf.3: SYNOPSIS: Use 'restrict' in prototypes

Both POSIX and glibc use 'restrict' in setvbuf(), setbuf().
Let's use it here too.

.../glibc$ grep_glibc_prototype setvbuf
libio/stdio.h:308:
extern int setvbuf (FILE *__restrict __stream, char *__restrict __buf,
		    int __modes, size_t __n) __THROW;
.../glibc$ grep_glibc_prototype setbuf
libio/stdio.h:304:
extern void setbuf (FILE *__restrict __stream, char *__restrict __buf) __THROW;
.../glibc$

Signed-off-by: Alejandro Colomar <alx.manpages@gmail.com>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
This commit is contained in:
Alejandro Colomar 2021-03-10 19:31:31 +01:00 committed by Michael Kerrisk
parent b4d9224a93
commit 92bb261d6c
1 changed files with 3 additions and 3 deletions

View File

@ -52,10 +52,10 @@ setbuf, setbuffer, setlinebuf, setvbuf \- stream buffering operations
.nf
.B #include <stdio.h>
.PP
.BI "int setvbuf(FILE *" stream ", char *" buf ", int " mode \
", size_t " size );
.BI "int setvbuf(FILE *restrict " stream ", char *restrict " buf ,
.BI " int " mode ", size_t " size );
.PP
.BI "void setbuf(FILE *" stream ", char *" buf );
.BI "void setbuf(FILE *restrict " stream ", char *restrict " buf );
.BI "void setbuffer(FILE *restrict " stream ", char *restrict " buf ,
.BI " size_t " size );
.BI "void setlinebuf(FILE *" stream );