Skip to content

Commit

Permalink
Merge pull request #90 from imobach/merge-sle-12-sp1
Browse files Browse the repository at this point in the history
Merge SLE 12 SP1
  • Loading branch information
imobachgs committed Mar 15, 2016
2 parents 5a397db + 1a8d8f2 commit 0c0d19c
Show file tree
Hide file tree
Showing 3 changed files with 17 additions and 7 deletions.
7 changes: 7 additions & 0 deletions package/yast2-users.changes
@@ -1,3 +1,10 @@
-------------------------------------------------------------------
Sat Mar 5 11:04:17 UTC 2016 - igonzalezsosa@suse.com

- Do not include inst-sys users when cloning the configuration
after the installation (bnc#965852)
- 3.1.46

-------------------------------------------------------------------
Thu Feb 18 09:23:10 CET 2016 - schubi@suse.de

Expand Down
2 changes: 1 addition & 1 deletion package/yast2-users.spec
Expand Up @@ -17,7 +17,7 @@


Name: yast2-users
Version: 3.1.45
Version: 3.1.46
Release: 0

BuildRoot: %{_tmppath}/%{name}-%{version}-build
Expand Down
15 changes: 9 additions & 6 deletions src/modules/Users.pm
Expand Up @@ -5861,8 +5861,9 @@ sub ImportUser {
}
}

if ($uid == -1) {
# check for existence of this user (and change it with given values)
if ($uid == -1 || Stage->initial()) {
# Check for existence of this user (and change it with given values).
# During 1st stage we simply match by username (bnc#965852).
my %existing = %{$self->GetUserByName ($username, "")};
if (%existing) {

Expand All @@ -5886,7 +5887,7 @@ sub ImportUser {
$cn eq "") {
$cn = $existing{"cn"} || "";
}
if ($gid == -1) {
if ($gid == -1 || Stage->initial()) {
$gid = $existing{"gidNumber"};
}
%ret = (
Expand Down Expand Up @@ -5976,8 +5977,9 @@ sub ImportGroup {
$gid = $group{"gid"} if (!defined $gid);
$gid = -1 if (!defined $gid);
}
if ($gid == -1) {
# check for existence of this group (and change it with given values)
if ($gid == -1 || Stage->initial()) {
# Check for existence of this group (and change it with given values).
# During 1st stage we simply match by groupname (bnc#965852).
my $existing = $self->GetGroupByName ($groupname, "");
if (ref ($existing) eq "HASH" && %{$existing}) {
$gid = $existing->{"gidNumber"};
Expand Down Expand Up @@ -6130,7 +6132,8 @@ sub Import {
# remove cache entries (#50265)
UsersCache->ResetCache ();

my $error_msg = Mode->test () ? "" : $self->ReadLocal ();
# Avoid to read local users during 1st stage (bnc#965852)
my $error_msg = (Mode->test() || Stage->initial()) ? "" : $self->ReadLocal ();
if ($error_msg) {
return 0;
}
Expand Down

0 comments on commit 0c0d19c

Please sign in to comment.