This is the mail archive of the
cygwin-developers@sourceware.cygnus.com
mailing list for the Cygwin project.
Re: /etc/passwd emulation
Kazuhiro Fujieda wrote:
>
> > Now, I came to realize it is not so bad idea that the uid become
> > always DEFAULT_UID when there is no /etc/passwd. I couldn't,
> > however, understand why the emulation code make the user name
> > `Administrator' when GetUserNameA() fails.
>
> So, I believe the following patch is meaningful.
>
> Sat Sep 11 02:21:53 1999 Kazuhiro Fujieda (fujieda@jaist.ac.jp)
>
> * passwd.cc (read_etc_passwd): /etc/passwd emulation use
> the user name `unknown' for an unknown user.
>
> [...]
Sorry, but I can't see the sense of this patch.
The call to getlogin() is the same as a call to GetUserName()
but if it fails, it returns 'unknown'. The original source of
read_etc_passwd() sets 'Administrator' as fallback and this is
the only difference. While the username is senseless on 9X
systems, on NT 'Administrator' would be a better fallback than
'unknown'.So, why should it be changed then...
Corinna