getsockopt.2: SYNOPSIS: Use 'restrict' in prototypes

POSIX specifies that the parameters of getsockopt()
shall be 'restrict'.  Glibc uses 'restrict' too.
Let's use it here too.

......

.../glibc$ grep_glibc_prototype getsockopt
socket/sys/socket.h:208:
extern int getsockopt (int __fd, int __level, int __optname,
		       void *__restrict __optval,
		       socklen_t *__restrict __optlen) __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-02-14 00:10:13 +01:00 committed by Michael Kerrisk
parent 8de93cea54
commit 78eb47fc8f
1 changed files with 1 additions and 1 deletions

View File

@ -50,7 +50,7 @@ getsockopt, setsockopt \- get and set options on sockets
.B #include <sys/socket.h>
.PP
.BI "int getsockopt(int " sockfd ", int " level ", int " optname ,
.BI " void *" optval ", socklen_t *" optlen );
.BI " void *restrict " optval ", socklen_t *restrict " optlen );
.BI "int setsockopt(int " sockfd ", int " level ", int " optname ,
.BI " const void *" optval ", socklen_t " optlen );
.fi