From: Mitchell Berger Date: Wed, 20 Jun 2001 08:16:10 +0000 (+0000) Subject: * lock-test.c: Changed to include server_internal.h instead of adb.h. X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=7ccf38f63759bbcc5397f0da0ef151a8f9024f80;p=thirdparty%2Fkrb5.git * lock-test.c: Changed to include server_internal.h instead of adb.h. (main): kadm5_server_handle_rec added for use with the new osa_adb_open_policy calling sequence. git-svn-id: svn://anonsvn.mit.edu/krb5/branches/incremental-propagation-branch@13408 dc483132-0cff-0310-8789-dd5450dbe970 --- diff --git a/src/lib/kadm5/unit-test/ChangeLog b/src/lib/kadm5/unit-test/ChangeLog index aa8b2fed87..318c0a685c 100644 --- a/src/lib/kadm5/unit-test/ChangeLog +++ b/src/lib/kadm5/unit-test/ChangeLog @@ -1,3 +1,9 @@ +2001-06-20 Mitchell Berger + + * lock-test.c: Changed to include server_internal.h instead of adb.h. + (main): kadm5_server_handle_rec added for use with the new + osa_adb_open_policy calling sequence. + 2001-06-20 Mitchell Berger * api.0/init.exp: Silly typo fixed. diff --git a/src/lib/kadm5/unit-test/lock-test.c b/src/lib/kadm5/unit-test/lock-test.c index 256954c857..faa4a442d6 100644 --- a/src/lib/kadm5/unit-test/lock-test.c +++ b/src/lib/kadm5/unit-test/lock-test.c @@ -6,7 +6,7 @@ #include #include #include -#include +#include char *whoami; @@ -26,6 +26,7 @@ int main(int argc, char **argv) krb5_context context; kadm5_config_params params; krb5_error_code kret; + kadm5_server_handle_rec kadm5_handle; whoami = argv[0]; @@ -52,7 +53,14 @@ int main(int argc, char **argv) exit(1); } - ret = osa_adb_open_policy(&policy_db, ¶ms); + /* XXX Horrible kludge. To get the generation number to increase for + * policy updates, the handle to the policy db needs a handle to the + * principal db so it can do a kdb_get_entry on the master principal. + * The only things it looks at are the context and params. + */ + kadm5_handle.context = context; + kadm5_handle.params = params; + ret = osa_adb_open_policy(&policy_db, ¶ms, &kadm5_handle); if (ret != OSA_ADB_OK) { com_err(whoami, ret, "while opening database"); exit(1);