* src/su.c: No need to call expire() if there are no shadow entry.

No need to convert a passwd entry into an spwd entry in that case.
This commit is contained in:
nekral-guest 2011-06-13 18:25:40 +00:00
parent 1ddde00b1d
commit aef33a89c2
2 changed files with 8 additions and 10 deletions

View File

@ -1,12 +1,14 @@
2011-06-12 Thomas Blein <tblein@tblein.eu>
* man/po/fr.po: French manpages translation
2011-06-05 Nicolas François <nicolas.francois@centraliens.net>
2011-06-10 Nicolas François <nicolas.francois@centraliens.net>
* src/su.c: Updating pwent after expire() is not useful. Only the
password information may have changed and they are not used
anymore afterwards.
* src/su.c: No need to call expire() if there are no shadow entry.
No need to convert a passwd entry into an spwd entry in that case.
2011-06-12 Thomas Blein <tblein@tblein.eu>
* man/po/fr.po: French manpages translation
2011-06-05 Nicolas François <nicolas.francois@centraliens.net>

View File

@ -863,11 +863,7 @@ int main (int argc, char **argv)
* expired accounts, but normal users can't become a user with an
* expired password.
*/
if (!amroot) {
if (NULL == spwd) {
spwd = pwd_to_spwd (&pwent);
}
if ((!amroot) && (NULL != spwd)) {
(void) expire (&pwent, spwd);
}