[13/14] getpwent_r.3: SYNOPSIS: Use 'restrict' in prototypes
Commit Message
glibc uses 'restrict' in getpwent_r(), fgetpwent_r().
Let's use it here too.
.../glibc$ grep_glibc_prototype getpwent_r
pwd/pwd.h:139:
extern int getpwent_r (struct passwd *__restrict __resultbuf,
char *__restrict __buffer, size_t __buflen,
struct passwd **__restrict __result)
__nonnull ((1, 2, 4));
.../glibc$ grep_glibc_prototype fgetpwent_r
pwd/pwd.h:166:
extern int fgetpwent_r (FILE *__restrict __stream,
struct passwd *__restrict __resultbuf,
char *__restrict __buffer, size_t __buflen,
struct passwd **__restrict __result)
__nonnull ((1, 2, 3, 5));
.../glibc$
Signed-off-by: Alejandro Colomar <alx.manpages@gmail.com>
---
man3/getpwent_r.3 | 11 +++++++----
1 file changed, 7 insertions(+), 4 deletions(-)
@@ -28,10 +28,13 @@ getpwent_r, fgetpwent_r \- get passwd file entry reentrantly
.nf
.B #include <pwd.h>
.PP
-.BI "int getpwent_r(struct passwd *" pwbuf ", char *" buf ,
-.BI " size_t " buflen ", struct passwd **" pwbufp );
-.BI "int fgetpwent_r(FILE *" stream ", struct passwd *" pwbuf ", char *" buf ,
-.BI " size_t " buflen ", struct passwd **" pwbufp );
+.BI "int getpwent_r(struct passwd *restrict " pwbuf ,
+.BI " char *restrict " buf ", size_t " buflen ,
+.BI " struct passwd **restrict " pwbufp );
+.BI "int fgetpwent_r(FILE *restrict " stream \
+", struct passwd *restrict " pwbuf ,
+.BI " char *restrict " buf ", size_t " buflen ,
+.BI " struct passwd **restrict " pwbufp );
.fi
.PP
.RS -4