This is the mail archive of the newlib@sources.redhat.com mailing list for the newlib project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: RFC and patch: pw_comment


Werner Almesberger wrote:
> 
> There's something puzzling in libc/unix/getpwent.c: it uses a field
> pw_comment which doesn't seem to exist on any Unix I know. 

I guess it's historical.

From an old SunOS-4 (dated 21 January 1990) man page:

man getpwent:

>       getpwent(),  getpwuid()  and  getpwnam()  each  return   a
>        pointer to an object with the following structure contain­
>        ing the fields of a line in the password file.  Each  line
>        in  the  file contains a passwd structure, declared in the
>        <pwd.h> header file:
> 
>               struct    passwd {
>                    char *pw_name;
>                    char *pw_passwd;
>                    uid_t     pw_uid;
>                    gid_t     pw_gid;
>                    int  pw_quota;
>                    char *pw_comment;
>                    char *pw_gecos;
>                    char *pw_dir;
>                    char *pw_shell;
>               };
>               struct passwd *getpwent(), *getpwuid(), *getpwnam();
> 
>        The fields pw_quota and pw_comment are unused;
> [...]


Ralf

-- 
Ralf Corsepius 
Forschungsinstitut fuer Anwendungsorientierte Wissensverarbeitung
(FAW)
Helmholtzstr. 16, 89081 Ulm, Germany     Tel: +49/731/501-8690
mailto:corsepiu@faw.uni-ulm.de           FAX: +49/731/501-999  
http://www.faw.uni-ulm.de

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]