diff options
-rw-r--r-- | perl-install/any.pm | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/perl-install/any.pm b/perl-install/any.pm index 99ca76db3..9dca58edd 100644 --- a/perl-install/any.pm +++ b/perl-install/any.pm @@ -65,7 +65,7 @@ sub create_user { run_program::rooted($::prefix, 'groupadd', '-g', $gid, $u->{name}); } } elsif ($u->{rename_from}) { - run_program::rooted($::prefix, 'groupadd', $u->{name}) and $gid = int getgrnam($u->{name}); + run_program::rooted($::prefix, 'groupmod', '-n', $u->{name}, $u->{rename_from}); } require authentication; @@ -83,7 +83,7 @@ sub create_user { my (undef, undef, $uid, $gid, undef, undef, undef, $home) = getpwnam($u->{name}); - if (@existing && $::isInstall && ($uid != $existing[4] || $gid != $existing[5]) || $u->{rename_from}) { + if (@existing && $::isInstall && ($uid != $existing[4] || $gid != $existing[5])) { log::l("chown'ing $home from $existing[4].$existing[5] to $uid.$gid"); require commands; eval { commands::chown_("-r", "$uid.$gid", "$::prefix$home") }; |