From d5971d2776e616d20b0b54dfe011a9530b5dabbc Mon Sep 17 00:00:00 2001 From: Nalin Dahyabhai Date: Mon, 25 Feb 2008 20:53:41 +0000 Subject: [PATCH] - add patch to suppress double-processing of /etc/krb5.conf when we build with --sysconfdir=/etc, thereby suppressing double-logging (#231147) --- krb5-1.6.2-doublelog.patch | 28 ---------------------------- krb5-trunk-doublelog.patch | 18 ++++++++++++++++++ krb5.spec | 8 ++++++-- 3 files changed, 24 insertions(+), 30 deletions(-) delete mode 100644 krb5-1.6.2-doublelog.patch create mode 100644 krb5-trunk-doublelog.patch diff --git a/krb5-1.6.2-doublelog.patch b/krb5-1.6.2-doublelog.patch deleted file mode 100644 index 0773cf4..0000000 --- a/krb5-1.6.2-doublelog.patch +++ /dev/null @@ -1,28 +0,0 @@ -Skip over duplicate entries in a profile's file list (closes #231147). Files -are parsed in the order specified, so skipping a duplicate the second (or -subsequent) time it's seen shouldn't break any applications. - -diff -up krb5-1.6.2/src/util/profile/prof_init.c krb5-1.6.2/src/util/profile/prof_init.c ---- krb5-1.6.2/src/util/profile/prof_init.c 2007-07-23 15:55:00.000000000 -0400 -+++ krb5-1.6.2/src/util/profile/prof_init.c 2007-07-23 15:54:53.000000000 -0400 -@@ -23,7 +23,7 @@ typedef int32_t prof_int32; - errcode_t KRB5_CALLCONV - profile_init(const_profile_filespec_t *files, profile_t *ret_profile) - { -- const_profile_filespec_t *fs; -+ const_profile_filespec_t *fs, *fs2; - profile_t profile; - prf_file_t new_file, last = 0; - errcode_t retval = 0; -@@ -37,6 +37,11 @@ profile_init(const_profile_filespec_t *f - /* if the filenames list is not specified return an empty profile */ - if ( files ) { - for (fs = files; !PROFILE_LAST_FILESPEC(*fs); fs++) { -+ for (fs2 = files; fs2 != fs; fs2++) -+ if (strcmp(*fs2, *fs) == 0) -+ break; -+ if (fs2 != fs) -+ continue; - retval = profile_open_file(*fs, &new_file); - /* if this file is missing, skip to the next */ - if (retval == ENOENT || retval == EACCES) { diff --git a/krb5-trunk-doublelog.patch b/krb5-trunk-doublelog.patch new file mode 100644 index 0000000..41db4d8 --- /dev/null +++ b/krb5-trunk-doublelog.patch @@ -0,0 +1,18 @@ +Don't double-log (actually, don't process /etc/krb5.conf twice) just +because we built with --sysconfdir=/etc. RT#3277 + +Index: src/include/Makefile.in +=================================================================== +--- src/include/Makefile.in (revision 20235) ++++ src/include/Makefile.in (working copy) +@@ -67,7 +67,9 @@ + -e "s+@SBINDIR+$(SBINDIR)+" \ + -e "s+@MODULEDIR+$(MODULE_DIR)+" \ + -e 's+@LOCALSTATEDIR+$(LOCALSTATEDIR)+' \ +- -e 's+@SYSCONFDIR+$(SYSCONFDIR)+' ++ -e 's+@SYSCONFDIR+$(SYSCONFDIR)+' \ ++ -e 's+:/etc/krb5.conf:/etc/krb5.conf"+:/etc/krb5.conf"+' \ ++ -e 's+"/etc/krb5.conf:/etc/krb5.conf"+"/etc/krb5.conf"+' + + OSCONFSRC = $(srcdir)/osconf.hin + diff --git a/krb5.spec b/krb5.spec index 7940aa3..c5bee63 100644 --- a/krb5.spec +++ b/krb5.spec @@ -81,7 +81,7 @@ Patch51: krb5-1.6-ldap-init.patch Patch52: krb5-1.6-ldap-man.patch Patch53: krb5-1.6-nodeplibs.patch Patch55: krb5-1.6.1-empty.patch -Patch56: krb5-1.6.2-doublelog.patch +Patch56: krb5-trunk-doublelog.patch Patch57: krb5-1.6.2-login_chdir.patch Patch58: krb5-1.6.2-key_exp.patch Patch59: krb5-trunk-kpasswd_tcp.patch @@ -226,6 +226,10 @@ to obtain initial credentials from a KDC using a private key and a certificate. %changelog +* Mon Feb 25 2008 Nalin Dahyabhai +- add patch to suppress double-processing of /etc/krb5.conf when we build + with --sysconfdir=/etc, thereby suppressing double-logging (#231147) + * Mon Feb 25 2008 Nalin Dahyabhai - remove a patch, to fix problems with interfaces which are "up" but which have no address assigned, which conflicted with a different fix for the same @@ -1308,7 +1312,7 @@ popd %patch52 -p0 -b .ldap_man %patch53 -p1 -b .nodeplibs #%patch55 -p1 -b .empty -#%patch56 -p1 -b .doublelog +%patch56 -p0 -b .doublelog #%patch57 -p1 -b .login_chdir %patch58 -p1 -b .key_exp %patch59 -p0 -b .kpasswd_tcp