diff options
author | Lars Wendler <polynomial-c@gentoo.org> | 2016-12-06 11:35:00 +0100 |
---|---|---|
committer | Lars Wendler <polynomial-c@gentoo.org> | 2016-12-06 11:35:00 +0100 |
commit | 6d77df88eaeaf655fe420153b0a77d931bdefa31 (patch) | |
tree | b0aae956a2e81afd903bb1ab3858121bf8e14583 /sys-apps/shadow/files | |
parent | kde-base/klipper -> kde-plasma/klipper (diff) | |
download | gentoo-6d77df88eaeaf655fe420153b0a77d931bdefa31.tar.gz gentoo-6d77df88eaeaf655fe420153b0a77d931bdefa31.tar.bz2 gentoo-6d77df88eaeaf655fe420153b0a77d931bdefa31.zip |
sys-apps/shadow: Fixed loading of defaults (bug #601802).
Package-Manager: portage-2.3.3
Diffstat (limited to 'sys-apps/shadow/files')
-rw-r--r-- | sys-apps/shadow/files/shadow-4.4-load_defaults.patch | 37 |
1 files changed, 37 insertions, 0 deletions
diff --git a/sys-apps/shadow/files/shadow-4.4-load_defaults.patch b/sys-apps/shadow/files/shadow-4.4-load_defaults.patch new file mode 100644 index 000000000000..4c0b84f68036 --- /dev/null +++ b/sys-apps/shadow/files/shadow-4.4-load_defaults.patch @@ -0,0 +1,37 @@ +From 507f96cdeb54079fb636c7ce21e371f7a16a520e Mon Sep 17 00:00:00 2001 +From: Tomas Mraz <tmraz@fedoraproject.org> +Date: Thu, 25 Aug 2016 11:20:34 +0200 +Subject: [PATCH] Fix regression in useradd not loading defaults properly. +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +The get_defaults() has to be called before processing the flags. + +Signed-off-by: Tomáš Mráz <tmraz@fedoraproject.org> +--- + src/useradd.c | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +diff --git a/src/useradd.c b/src/useradd.c +index fefa234..6c43e7e 100644 +--- a/src/useradd.c ++++ b/src/useradd.c +@@ -2027,6 +2027,8 @@ int main (int argc, char **argv) + is_shadow_grp = sgr_file_present (); + #endif + ++ get_defaults (); ++ + process_flags (argc, argv); + + #ifdef ENABLE_SUBIDS +@@ -2036,8 +2038,6 @@ int main (int argc, char **argv) + (!user_id || (user_id <= uid_max && user_id >= uid_min)); + #endif /* ENABLE_SUBIDS */ + +- get_defaults (); +- + #ifdef ACCT_TOOLS_SETUID + #ifdef USE_PAM + { |