Skip to content

Commit

Permalink
Respect db_home setting even for the SYSTEM account
Browse files Browse the repository at this point in the history
We should not blindly set the home directory of the SYSTEM account to
/home/SYSTEM, especially not when that value disagrees with what is
configured via the `db_home` line in the `/etc/nsswitch.conf` file.

This fixes git-for-windows/git#435

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
  • Loading branch information
dscho committed Sep 5, 2022
1 parent ad711d9 commit 90d8aad
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion winsup/cygwin/uinfo.cc
Original file line number Diff line number Diff line change
Expand Up @@ -2307,7 +2307,11 @@ pwdgrp::fetch_account_from_windows (fetch_user_arg_t &arg, cyg_ldap *pldap)
it to a well-known group here. */
if (acc_type == SidTypeUser
&& (sid_sub_auth_count (sid) <= 3 || sid_id_auth (sid) == 11))
acc_type = SidTypeWellKnownGroup;
{
acc_type = SidTypeWellKnownGroup;
home = cygheap->pg.get_home (pldap, sid, dom, domain, name,
fully_qualified_name);
}
switch ((int) acc_type)
{
case SidTypeUser:
Expand Down

0 comments on commit 90d8aad

Please sign in to comment.