mirror of https://github.com/mkerrisk/man-pages
getpwnam.3: Rename arguments to getpwnam_r() and getpwuid_r()
s/pwbuf/pwd/ and s/pwbufp/result/, for consistency with POSIX.1 argument names. Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
This commit is contained in:
parent
2ac1e1d3d4
commit
3adc12e97f
|
@ -41,13 +41,13 @@ getpwnam, getpwnam_r, getpwuid, getpwuid_r \- get password file entry
|
|||
.sp
|
||||
.BI "struct passwd *getpwuid(uid_t " uid );
|
||||
.sp
|
||||
.BI "int getpwnam_r(const char *" name ", struct passwd *" pwbuf ,
|
||||
.BI "int getpwnam_r(const char *" name ", struct passwd *" pwd ,
|
||||
.br
|
||||
.BI " char *" buf ", size_t " buflen ", struct passwd **" pwbufp );
|
||||
.BI " char *" buf ", size_t " buflen ", struct passwd **" result );
|
||||
.sp
|
||||
.BI "int getpwuid_r(uid_t " uid ", struct passwd *" pwbuf ,
|
||||
.BI "int getpwuid_r(uid_t " uid ", struct passwd *" pwd ,
|
||||
.br
|
||||
.BI " char *" buf ", size_t " buflen ", struct passwd **" pwbufp );
|
||||
.BI " char *" buf ", size_t " buflen ", struct passwd **" result );
|
||||
.fi
|
||||
.sp
|
||||
.in -4n
|
||||
|
@ -86,7 +86,7 @@ and
|
|||
functions obtain the same information, but store the retrieved
|
||||
.I passwd
|
||||
structure in the space pointed to by
|
||||
.IR pwbuf .
|
||||
.IR pwd .
|
||||
This
|
||||
.I passwd
|
||||
structure contains pointers to strings, and these strings
|
||||
|
@ -96,7 +96,7 @@ of size
|
|||
.IR buflen .
|
||||
A pointer to the result (in case of success) or NULL (in case no entry
|
||||
was found or an error occurred) is stored in
|
||||
.IR *pwbufp .
|
||||
.IR *result .
|
||||
.PP
|
||||
The \fIpasswd\fP structure is defined in \fI<pwd.h>\fP as follows:
|
||||
.sp
|
||||
|
@ -148,14 +148,14 @@ On success,
|
|||
and
|
||||
.BR getpwuid_r ()
|
||||
return zero, and set
|
||||
.IR *pwbufp
|
||||
.IR *result
|
||||
to
|
||||
.IR pwbuf .
|
||||
.IR pwd .
|
||||
If no matching password record was found,
|
||||
these functions return 0 and store NULL in
|
||||
.IR *pwbufp .
|
||||
.IR *result .
|
||||
In case of error, an error number is returned, and NULL is stored in
|
||||
.IR *pwbufp .
|
||||
.IR *result .
|
||||
.SH ERRORS
|
||||
.TP
|
||||
.BR 0 " or " ENOENT " or " ESRCH " or " EBADF " or " EPERM " or ... "
|
||||
|
|
Loading…
Reference in New Issue