[Pkg-shadow-commits] r1398 - in upstream/trunk: . lib src
nekral-guest at alioth.debian.org
nekral-guest at alioth.debian.org
Sun Nov 18 23:20:02 UTC 2007
Author: nekral-guest
Date: 2007-11-18 23:20:02 +0000 (Sun, 18 Nov 2007)
New Revision: 1398
Modified:
upstream/trunk/ChangeLog
upstream/trunk/lib/Makefile.am
upstream/trunk/src/login.c
Log:
Add forgotten files in the previous ChangeLog entry.
Modified: upstream/trunk/ChangeLog
===================================================================
--- upstream/trunk/ChangeLog 2007-11-18 23:15:26 UTC (rev 1397)
+++ upstream/trunk/ChangeLog 2007-11-18 23:20:02 UTC (rev 1398)
@@ -10,7 +10,7 @@
available.
* libmisc/limits.c, libmisc/entry.c, libmisc/chowntty.c,
libmisc/addgrps.c, libmisc/myname.c, libmisc/rlogin.c,
- libmisc/pwdcheck.c, src/newgrp.c, src/login_nopam.c,
+ libmisc/pwdcheck.c, src/newgrp.c, src/login_nopam.c, src/login.c,
src/userdel.c, src/lastlog.c, src/grpck.c, src/gpasswd.c,
src/newusers.c, src/chpasswd.c, src/chfn.c, src/groupmems.c,
src/usermod.c, src/expiry.c, src/groupdel.c, src/chgpasswd.c,
@@ -30,7 +30,7 @@
Note: the getpwent/getgrent calls should probably be checked also.
* src/groupdel.c, src/expiry.c: Fix typos in comments.
* src/groupmod.c: Re-indent.
- * libmisc/Makefile.am, lib/groupmem.c, lib/groupio.c, lib/pwmem.c,
+ * lib/Makefile.am, lib/groupmem.c, lib/groupio.c, lib/pwmem.c,
lib/pwio.c, lib/shadowmem.c, lib/shadowio.c: Move the __<xx>_dup
functions (used by the xget... functions) from the <xx>io.c files
to the new <xx>mem.c files. This avoid linking some utils against
Modified: upstream/trunk/lib/Makefile.am
===================================================================
--- upstream/trunk/lib/Makefile.am 2007-11-18 23:15:26 UTC (rev 1397)
+++ upstream/trunk/lib/Makefile.am 2007-11-18 23:20:02 UTC (rev 1398)
@@ -19,6 +19,7 @@
getdef.c \
getdef.h \
groupio.c \
+ groupmem.c \
groupio.h \
gshadow.c \
lockpw.c \
@@ -32,6 +33,7 @@
pwauth.h \
pwio.c \
pwio.h \
+ pwmem.c \
sgetgrent.c \
sgetpwent.c \
sgroupio.c \
@@ -39,6 +41,7 @@
shadow.c \
shadowio.c \
shadowio.h \
+ shadowmem.c \
utent.c
# These files are unneeded for some reason, listed in
Modified: upstream/trunk/src/login.c
===================================================================
--- upstream/trunk/src/login.c 2007-11-18 23:15:26 UTC (rev 1397)
+++ upstream/trunk/src/login.c 2007-11-18 23:20:02 UTC (rev 1398)
@@ -647,7 +647,7 @@
(const void **) &pam_user);
if (pam_user && pam_user[0]) {
- pwd = getpwnam(pam_user);
+ pwd = xgetpwnam(pam_user);
if (pwd) {
pwent = *pwd;
failent_user = pwent.pw_name;
@@ -693,6 +693,7 @@
char buf[64];
audit_fd = audit_open ();
+ /* local, no need for xgetpwnam */
pw = getpwnam (username);
if (pw) {
snprintf (buf, sizeof (buf),
@@ -738,9 +739,9 @@
retcode =
pam_get_item (pamh, PAM_USER, (const void **) &pam_user);
setpwent ();
- pwd = getpwnam (pam_user);
+ pwd = xgetpwnam (pam_user);
if (!pwd) {
- SYSLOG ((LOG_ERR, "getpwnam(%s) failed",
+ SYSLOG ((LOG_ERR, "xgetpwnam(%s) failed",
getdef_bool ("LOG_UNKFAIL_ENAB") ?
pam_user : "UNKNOWN"));
exit (1);
@@ -779,10 +780,10 @@
#endif /* ! USE_PAM */
#ifdef USE_PAM
- if (!(pwd = getpwnam (pam_user))) {
+ if (!(pwd = xgetpwnam (pam_user))) {
pwent.pw_name = pam_user;
#else
- if (!(pwd = getpwnam (username))) {
+ if (!(pwd = xgetpwnam (username))) {
pwent.pw_name = username;
#endif
strcpy (temp_pw, "!");
@@ -797,6 +798,7 @@
#ifndef USE_PAM
spwd = NULL;
if (pwd && strcmp (pwd->pw_passwd, SHADOW_PASSWD_STRING) == 0) {
+ /* !USE_PAM, no need for xgetspnam */
spwd = getspnam (username);
if (spwd)
pwent.pw_passwd = spwd->sp_pwdp;
@@ -996,7 +998,9 @@
*/
if (spwd) { /* check for age of password */
if (expire (&pwent, spwd)) {
+ /* !USE_PAM, no need for xgetpwnam */
pwd = getpwnam (username);
+ /* !USE_PAM, no need for xgetspnam */
spwd = getspnam (username);
if (pwd)
pwent = *pwd;
More information about the Pkg-shadow-commits
mailing list