Jon Turney wrote:
On 12/07/2022 13:50, Jon Turney wrote:
[Replying to the right list this time...]
On 09/07/2022 13:21, Christian Franke wrote:
[...]
The UserSettings ctor has a somewhat hidden side effect which sets
root_scope correctly:
UserSettings::UserSettings(...);
open_settings("setup.rc", ...);
io_stream::open("cygfile:///etc/setup/setup.rc", ...);
io_stream_cygfile::io_stream_cygfile("/etc/setup/setup.rc", ...);
get_root_dir_now();
read_mounts("");
read_mounts_nt("");
root_scope = isuser ? IDC_ROOT_USER : IDC_ROOT_SYSTEM;
Conclusion: Regression introduced Feb 24, 2012 (befc9dd).
Thanks for tracking this down.
That just seems... fractally wrong.
I kind of lost track of this. Is there anything else needed to fix
the original problem here? Or is it solved by the change to defer
setting the group until after root_scope is known?
The group seems to be correctly set now.
An old problem still remains: root_scope always ends up as
IDC_ROOT_SYSTEM if setup is run elevated, regardless off GUI setting.
Apply the temporary patch from here to see what happens:
https://sourceware.org/pipermail/cygwin-apps/2022-July/042151.html
Possibly difficult to fix, in particular in conjunction with later
changes via [< Back] button. An easier approach: Remove the GUI setting
and connect root_scope to -B option.