diff mbox series

[19/23] realpath.3: SYNOPSIS: Use 'restrict' in prototypes

Message ID 20210308185331.242176-20-alx.manpages@gmail.com
State New
Headers show
Series man3: SYNOPSIS: Use 'restrict' in prototypes (batch 4) | expand

Commit Message

Alejandro Colomar March 8, 2021, 6:53 p.m. UTC
Both POSIX and glibc use 'restrict' in realpath().
Let's use it here too.

.../glibc$ grep_glibc_prototype realpath
stdlib/stdlib.h:800:
extern char *realpath (const char *__restrict __name,
		       char *__restrict __resolved) __THROW __wur;
.../glibc$

Signed-off-by: Alejandro Colomar <alx.manpages@gmail.com>
---
 man3/realpath.3 | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
diff mbox series

Patch

diff --git a/man3/realpath.3 b/man3/realpath.3
index 643cdaaec..100567217 100644
--- a/man3/realpath.3
+++ b/man3/realpath.3
@@ -33,7 +33,8 @@  realpath \- return the canonicalized absolute pathname
 .B #include <limits.h>
 .B #include <stdlib.h>
 .PP
-.BI "char *realpath(const char *" path ", char *" resolved_path );
+.BI "char *realpath(const char *restrict " path ,
+.BI "               char *restrict " resolved_path );
 .fi
 .PP
 .RS -4