DOC HOME SITE MAP MAN PAGES GNU INFO SEARCH PRINT BOOK
 

putpwent(S-osr5)


putpwent -- write password file entry

Syntax

cc . . . -lc

#include <pwd.h>

int putpwent (p, f) struct passwd *p; FILE *f;

Description

The putpwent routine is the inverse of the getpwent(S-osr5) routine. Given a pointer to a passwd structure created by getpwent (or two other routines that appear on the same man page - getpwuid(S-osr5) or getpwnam(S-osr5)), putpwent writes a line which matches the format of /etc/passwd onto the stream f.

Return value

Upon successful completion, the putpwent routine returns a value of zero. If an error was detected during its operation, it will return a non-zero value.

See also

getpwent(S-osr5), getpwuid(S-osr5), getpwnam(S-osr5)

Standards conformance

putpwent is not part of any currently supported standard; it was developed by UNIX System Laboratories, Inc. and is maintained by The SCO Group.
© 2005 The SCO Group, Inc. All rights reserved.
SCO OpenServer Release 6.0.0 -- 02 June 2005