diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-06-17 10:51:52 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-06-17 10:51:52 +0000 |
commit | 4ad94864781f48b1a4b77f9cfb934622bf756ba1 (patch) | |
tree | 3900955c1886e6d2570fea7125ee1f01bafe876d /upstream/opensuse-tumbleweed/man3/getpwnam.3 | |
parent | Adding upstream version 4.22.0. (diff) | |
download | manpages-l10n-4ad94864781f48b1a4b77f9cfb934622bf756ba1.tar.xz manpages-l10n-4ad94864781f48b1a4b77f9cfb934622bf756ba1.zip |
Adding upstream version 4.23.0.upstream/4.23.0
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'upstream/opensuse-tumbleweed/man3/getpwnam.3')
-rw-r--r-- | upstream/opensuse-tumbleweed/man3/getpwnam.3 | 35 |
1 files changed, 17 insertions, 18 deletions
diff --git a/upstream/opensuse-tumbleweed/man3/getpwnam.3 b/upstream/opensuse-tumbleweed/man3/getpwnam.3 index 3e6af831..3547ca51 100644 --- a/upstream/opensuse-tumbleweed/man3/getpwnam.3 +++ b/upstream/opensuse-tumbleweed/man3/getpwnam.3 @@ -15,7 +15,7 @@ .\" Modified 2003-11-15 by aeb .\" 2008-11-07, mtk, Added an example program for getpwnam_r(). .\" -.TH getpwnam 3 2023-07-20 "Linux man-pages 6.05.01" +.TH getpwnam 3 2024-05-02 "Linux man-pages (unreleased)" .SH NAME getpwnam, getpwnam_r, getpwuid, getpwuid_r \- get password file entry .SH LIBRARY @@ -25,10 +25,10 @@ Standard C library .nf .B #include <sys/types.h> .B #include <pwd.h> -.PP +.P .BI "struct passwd *getpwnam(const char *" name ); .BI "struct passwd *getpwuid(uid_t " uid ); -.PP +.P .BI "int getpwnam_r(const char *restrict " name ", \ struct passwd *restrict " pwd , .BI " char " buf "[restrict ." buflen "], size_t " buflen , @@ -37,12 +37,12 @@ struct passwd *restrict " pwd , .BI " char " buf "[restrict ." buflen "], size_t " buflen , .BI " struct passwd **restrict " result ); .fi -.PP +.P .RS -4 Feature Test Macro Requirements for glibc (see .BR feature_test_macros (7)): .RE -.PP +.P .BR getpwnam_r (), .BR getpwuid_r (): .nf @@ -59,16 +59,16 @@ the broken-out fields of the record in the password database NIS, and LDAP) that matches the username .IR name . -.PP +.P The .BR getpwuid () function returns a pointer to a structure containing the broken-out fields of the record in the password database that matches the user ID .IR uid . -.PP +.P The \fIpasswd\fP structure is defined in \fI<pwd.h>\fP as follows: -.PP +.P .in +4n .EX struct passwd { @@ -82,11 +82,11 @@ struct passwd { }; .EE .in -.PP +.P See .BR passwd (5) for more information about these fields. -.PP +.P The .BR getpwnam_r () and @@ -108,15 +108,15 @@ of size 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 *result . -.PP +.P The call -.PP +.P .in +4n .EX sysconf(_SC_GETPW_R_SIZE_MAX) .EE .in -.PP +.P returns either \-1, without changing .IR errno , or an initial suggested size for @@ -140,7 +140,7 @@ is set to indicate the error. If one wants to check .I errno after the call, it should be set to zero before the call. -.PP +.P The return value may point to a static area, and may be overwritten by subsequent calls to .BR getpwent (3), @@ -149,7 +149,7 @@ or .BR getpwuid (). (Do not pass the returned pointer to .BR free (3).) -.PP +.P On success, .BR getpwnam_r () and @@ -235,7 +235,6 @@ T} Thread safety T{ MT-Safe locale T} .TE -.sp 1 .SH VERSIONS The .I pw_gecos @@ -265,7 +264,7 @@ situation: 0, ENOENT, EBADF, ESRCH, EWOULDBLOCK, EPERM, and probably others. .\" FreeBSD 4.8, OpenBSD 3.2, NetBSD 1.6 - give EPERM .\" SunOS 5.8 - gives EBADF .\" Tru64 5.1b, HP-UX-11i, SunOS 5.7 - give 0 -.PP +.P The .I pw_dir field contains the name of the initial working directory of the user. @@ -288,7 +287,7 @@ The program below demonstrates the use of .BR getpwnam_r () to find the full username and user ID for the username supplied as a command-line argument. -.PP +.P .\" SRC BEGIN (getpwnam.c) .EX #include <errno.h> |