* mount.cc (mount_info::init): Take bool argument and allow to
initialize mount table in two steps, system and user, depending on bool value. * mount.h (class mount_info): Align declaration of init function to above change. * shared.cc (user_info::initialize): Initialize mount table in two steps to allow internal_getpwsid to create valid POSIX paths from DOS paths given in AD. Add comments. * uinfo.cc (cygheap_pwdgrp::get_home): Allow DOS paths in NSS_SCHEME_FREEATTR attributes. (cygheap_pwdgrp::get_shell): Ditto.
This commit is contained in:
@@ -230,13 +230,18 @@ user_info::initialize ()
|
||||
if (!sversion)
|
||||
{
|
||||
cb = sizeof (*user_shared);
|
||||
/* Initialize mount table from system fstab prior to calling
|
||||
internal_getpwsid. This allows to convert pw_dir and pw_shell
|
||||
paths given in DOS notation to valid POSIX paths. */
|
||||
mountinfo.init (false);
|
||||
cygpsid sid (cygheap->user.sid ());
|
||||
struct passwd *pw = internal_getpwsid (sid);
|
||||
/* Correct the user name with what's defined in /etc/passwd before
|
||||
loading the user fstab file. */
|
||||
if (pw)
|
||||
cygheap->user.set_name (pw->pw_name);
|
||||
mountinfo.init (); /* Initialize the mount table. */
|
||||
/* After fetching the user infos, add mount entries from user's fstab. */
|
||||
mountinfo.init (true);
|
||||
}
|
||||
else if (sversion != CURR_USER_MAGIC)
|
||||
sversion.multiple_cygwin_problem ("user shared memory version", version,
|
||||
|
Reference in New Issue
Block a user