From: Ken Raeburn Date: Mon, 5 Sep 2011 01:58:48 +0000 (+0000) Subject: Instead of passing a 0 to add_new_mkey for kvno and leaving X-Git-Tag: krb5-1.10-alpha1~227 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=c7586cc94818ff865ca9a057d32c0fb40a7c3688;p=krb5.git Instead of passing a 0 to add_new_mkey for kvno and leaving new_mkey_kvno (used when stashing) uninitialized, use get_next_kvno to set the latter to the only non-zero value that add_new_mkey will accept. ticket: 6617 git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@25148 dc483132-0cff-0310-8789-dd5450dbe970 --- diff --git a/src/kadmin/dbutil/kdb5_mkey.c b/src/kadmin/dbutil/kdb5_mkey.c index e5da1927e..395299410 100644 --- a/src/kadmin/dbutil/kdb5_mkey.c +++ b/src/kadmin/dbutil/kdb5_mkey.c @@ -299,7 +299,9 @@ kdb5_add_mkey(int argc, char *argv[]) goto cleanup_return; } - retval = add_new_mkey(util_context, master_entry, &new_mkeyblock, 0); + new_mkey_kvno = get_next_kvno(util_context, master_entry); + retval = add_new_mkey(util_context, master_entry, &new_mkeyblock, + new_mkey_kvno); if (retval) { com_err(progname, retval, _("adding new master key to master principal"));