[PATCH 05/22] inet_ntop.3: SYNOPSIS: Use 'restrict' in prototypes
Alejandro Colomar
alx.manpages@gmail.com
Fri Mar 5 23:50:49 GMT 2021
Both POSIX and glibc use 'restrict' in inet_ntop().
Let's use it here too.
.../glibc$ grep_glibc_prototype inet_ntop
inet/arpa/inet.h:64:
extern const char *inet_ntop (int __af, const void *__restrict __cp,
char *__restrict __buf, socklen_t __len)
__THROW;
.../glibc$
Signed-off-by: Alejandro Colomar <alx.manpages@gmail.com>
---
man3/inet_ntop.3 | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/man3/inet_ntop.3 b/man3/inet_ntop.3
index 9abb9556d..fc15ba859 100644
--- a/man3/inet_ntop.3
+++ b/man3/inet_ntop.3
@@ -30,8 +30,8 @@ inet_ntop \- convert IPv4 and IPv6 addresses from binary to text form
.nf
.B #include <arpa/inet.h>
.PP
-.BI "const char *inet_ntop(int " "af" ", const void *" "src" ,
-.BI " char *" "dst" ", socklen_t " "size" );
+.BI "const char *inet_ntop(int " af ", const void *restrict " src ,
+.BI " char *restrict " dst ", socklen_t " size );
.fi
.SH DESCRIPTION
This function converts the network address structure
--
2.30.1.721.g45526154a5
More information about the Libc-alpha
mailing list