Skip to content

Commit

Permalink
* lock-test.c: Changed to include server_internal.h instead of adb.h.
Browse files Browse the repository at this point in the history
(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
  • Loading branch information
mitchb committed Jun 20, 2001
1 parent 2a7fd1a commit 207b3fe
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 2 deletions.
6 changes: 6 additions & 0 deletions src/lib/kadm5/unit-test/ChangeLog
@@ -1,3 +1,9 @@
2001-06-20 Mitchell Berger <mitchb@mit.edu>

* 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 <mitchb@mit.edu>

* api.0/init.exp: Silly typo fixed.
Expand Down
12 changes: 10 additions & 2 deletions src/lib/kadm5/unit-test/lock-test.c
Expand Up @@ -6,7 +6,7 @@
#include <stdio.h>
#include <krb5.h>
#include <kadm5/admin.h>
#include <kadm5/adb.h>
#include <kadm5/server_internal.h>

char *whoami;

Expand All @@ -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];

Expand All @@ -52,7 +53,14 @@ int main(int argc, char **argv)
exit(1);
}

ret = osa_adb_open_policy(&policy_db, &params);
/* 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, &params, &kadm5_handle);
if (ret != OSA_ADB_OK) {
com_err(whoami, ret, "while opening database");
exit(1);
Expand Down

0 comments on commit 207b3fe

Please sign in to comment.