rpms/pam/devel pam-0.79-cleanup-redhat.patch,1.4,1.5
fedora-cvs-commits at redhat.com
fedora-cvs-commits at redhat.com
Thu Jun 9 21:33:51 UTC 2005
- Previous message (by thread): rpms/pam/devel pam-0.79-cleanup-redhat.patch, 1.3, 1.4 pam.spec, 1.77, 1.78
- Next message (by thread): rpms/kernel/devel patch-2.6.12-rc6-git3.bz2.sign, NONE, 1.1 .cvsignore, 1.157, 1.158 kernel-2.6.spec, 1.1378, 1.1379 upstream, 1.86, 1.87 patch-2.6.12-rc6-git1.bz2.sign, 1.1, NONE
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
Author: tmraz
Update of /cvs/dist/rpms/pam/devel
In directory cvs.devel.redhat.com:/tmp/cvs-serv615
Modified Files:
pam-0.79-cleanup-redhat.patch
Log Message:
- don't forget to include errno.h
pam-0.79-cleanup-redhat.patch:
pam_console/pam_console.c | 1 +
pam_loginuid/pam_loginuid.8 | 2 --
pam_loginuid/pam_loginuid.c | 15 +++++++++------
pam_timestamp/pam_timestamp.c | 2 ++
4 files changed, 12 insertions(+), 8 deletions(-)
Index: pam-0.79-cleanup-redhat.patch
===================================================================
RCS file: /cvs/dist/rpms/pam/devel/pam-0.79-cleanup-redhat.patch,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -r1.4 -r1.5
--- pam-0.79-cleanup-redhat.patch 9 Jun 2005 21:28:52 -0000 1.4
+++ pam-0.79-cleanup-redhat.patch 9 Jun 2005 21:33:47 -0000 1.5
@@ -8,34 +8,41 @@
err = PAM_SESSION_ERR; goto return_error;
}
consoleuser = _do_malloc(st.st_size+1);
---- Linux-PAM-0.79/modules/pam_loginuid/pam_loginuid.c.rhcleanup 2005-03-31 18:39:58.000000000 +0200
-+++ Linux-PAM-0.79/modules/pam_loginuid/pam_loginuid.c 2005-06-09 23:23:53.000000000 +0200
-@@ -56,16 +56,18 @@
+--- Linux-PAM-0.79/modules/pam_loginuid/pam_loginuid.c.rhcleanup 2005-03-31 18:39:58.000000000 +0200
++++ Linux-PAM-0.79/modules/pam_loginuid/pam_loginuid.c 2005-06-09 23:31:52.000000000 +0200
+@@ -29,6 +29,7 @@
+ #include <pwd.h>
+ #include <unistd.h>
+ #include <limits.h>
++#include <errno.h>
+
+ #include <security/pam_modules.h>
+ #include <security/_pam_modutil.h>
+@@ -56,16 +57,18 @@
static int set_loginuid(uid_t uid)
{
- int fd, count, rc = 0;
-- char fn[PATH_MAX];
- char loginuid[16];
-
-- memset(loginuid, 0, sizeof(loginuid));
- count = snprintf(loginuid, sizeof(loginuid), "%d", uid);
-- snprintf(fn, sizeof(fn), "/proc/%d/loginuid", getpid());
-- fd = open(fn, O_NOFOLLOW|O_WRONLY|O_TRUNC);
-+ fd = open("/proc/self/loginuid", O_NOFOLLOW|O_WRONLY|O_TRUNC);
- if (fd < 0) {
-- _pam_log(LOG_ERR, "set_loginuid failed opening loginuid\n");
-- return 1;
-+ int loglevel = LOG_DEBUG;
-+ if (errno != ENOENT) {
-+ rc = 1;
-+ loglevel = LOG_ERR;
-+ }
-+ _pam_log(loglevel, "set_loginuid failed opening loginuid\n");
-+ return rc;
- }
- if (_pammodutil_write(fd, loginuid, count) != count)
- rc = 1;
---- Linux-PAM-0.79/modules/pam_loginuid/pam_loginuid.8.rhcleanup 2005-03-31 18:39:58.000000000 +0200
+ int fd, count, rc = 0;
+- char fn[PATH_MAX];
+ char loginuid[16];
+
+- memset(loginuid, 0, sizeof(loginuid));
+ count = snprintf(loginuid, sizeof(loginuid), "%d", uid);
+- snprintf(fn, sizeof(fn), "/proc/%d/loginuid", getpid());
+- fd = open(fn, O_NOFOLLOW|O_WRONLY|O_TRUNC);
++ fd = open("/proc/self/loginuid", O_NOFOLLOW|O_WRONLY|O_TRUNC);
+ if (fd < 0) {
+- _pam_log(LOG_ERR, "set_loginuid failed opening loginuid\n");
+- return 1;
++ int loglevel = LOG_DEBUG;
++ if (errno != ENOENT) {
++ rc = 1;
++ loglevel = LOG_ERR;
++ }
++ _pam_log(loglevel, "set_loginuid failed opening loginuid\n");
++ return rc;
+ }
+ if (_pammodutil_write(fd, loginuid, count) != count)
+ rc = 1;--- Linux-PAM-0.79/modules/pam_loginuid/pam_loginuid.8.rhcleanup 2005-03-31 18:39:58.000000000 +0200
+++ Linux-PAM-0.79/modules/pam_loginuid/pam_loginuid.8 2005-05-19 20:59:49.456022913 +0200
@@ -15,8 +15,6 @@
.SH EXAMPLE
- Previous message (by thread): rpms/pam/devel pam-0.79-cleanup-redhat.patch, 1.3, 1.4 pam.spec, 1.77, 1.78
- Next message (by thread): rpms/kernel/devel patch-2.6.12-rc6-git3.bz2.sign, NONE, 1.1 .cvsignore, 1.157, 1.158 kernel-2.6.spec, 1.1378, 1.1379 upstream, 1.86, 1.87 patch-2.6.12-rc6-git1.bz2.sign, 1.1, NONE
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
More information about the fedora-cvs-commits
mailing list