svn rev #24667: trunk/src/kadmin/dbutil/

ghudson@MIT.EDU ghudson at MIT.EDU
Sat Feb 26 21:35:04 EST 2011


http://src.mit.edu/fisheye/changelog/krb5/?cs=24667
Commit By: ghudson
Log Message:
ticket: 6875
tags: pullup
target_version: 1.9.1

Make sure ulog_map() is invoked whenever we open the database in
kdb5_util.  Fixes all of the master key rollover commands in the
presence of iprop.  Reported by kacarstensen at csupomona.edu.



Changed Files:
U   trunk/src/kadmin/dbutil/dump.c
U   trunk/src/kadmin/dbutil/kdb5_util.c
Modified: trunk/src/kadmin/dbutil/dump.c
===================================================================
--- trunk/src/kadmin/dbutil/dump.c	2011-02-25 19:53:04 UTC (rev 24666)
+++ trunk/src/kadmin/dbutil/dump.c	2011-02-27 02:35:04 UTC (rev 24667)
@@ -1283,14 +1283,6 @@
         fprintf(arglist.ofile, "%s", dump->header);
 
         if (dump_sno) {
-            if (ulog_map(util_context, global_params.iprop_logfile,
-                         global_params.iprop_ulogsize, FKCOMMAND, db_args)) {
-                fprintf(stderr,
-                        _("%s: Could not map log\n"), progname);
-                exit_status++;
-                goto unlock_and_return;
-            }
-
             /*
              * We grab the lock twice (once again in the iterator call),
              * but that's ok since the lock func handles incr locks held.

Modified: trunk/src/kadmin/dbutil/kdb5_util.c
===================================================================
--- trunk/src/kadmin/dbutil/kdb5_util.c	2011-02-25 19:53:04 UTC (rev 24666)
+++ trunk/src/kadmin/dbutil/kdb5_util.c	2011-02-27 02:35:04 UTC (rev 24667)
@@ -499,6 +499,17 @@
         return(1);
     }
 
+    if (global_params.iprop_enabled) {
+        if (ulog_map(util_context, global_params.iprop_logfile,
+                     global_params.iprop_ulogsize, FKCOMMAND,
+                     db5util_db_args)) {
+            fprintf(stderr, _("%s: Could not map log\n"),
+                    progname);
+            exit_status++;
+            return(1);
+        }
+    }
+
     valid_master_key = 1;
     dbactive = TRUE;
     return 0;




More information about the cvs-krb5 mailing list