]> git.ipfire.org Git - thirdparty/krb5.git/commitdiff
Reset ulog header if iprop load fails
authorGreg Hudson <ghudson@mit.edu>
Fri, 15 Mar 2013 17:03:26 +0000 (13:03 -0400)
committerGreg Hudson <ghudson@mit.edu>
Fri, 15 Mar 2013 17:03:26 +0000 (13:03 -0400)
If an iprop slave tries to load a dump from the master and it fails,
reset the ulog header so we take another full dump, instead of
reporting that the slave is current when it isn't.  Reported by
Richard Basch <basch@alum.mit.edu>.

ticket: 7588
target_version: 1.11.2
tags: pullup

src/kadmin/dbutil/dump.c

index f32699994007abe94729e2279dd93d730aa1a8c3..7b0d1dc2605ba787b969bbe5a4c933f80b4d99b0 100644 (file)
@@ -1691,6 +1691,8 @@ load_db(int argc, char **argv)
 cleanup:
     /* If we created a temporary DB but didn't succeed, destroy it. */
     if (exit_status && temp_db_created) {
+        if (log_ctx && log_ctx->iproprole)
+            ulog_init_header(util_context);
         ret = krb5_db_destroy(util_context, db5util_db_args);
         /* Ignore a not supported error since there is nothing to do about
          * it anyway. */