* client_init.c (kadm5_destroy): Free handle->lhandle field, call
authorEzra Peisach <epeisach@mit.edu>
Mon, 13 Oct 1997 14:56:53 +0000 (14:56 +0000)
committerEzra Peisach <epeisach@mit.edu>
Mon, 13 Oct 1997 14:56:53 +0000 (14:56 +0000)
        kadm5_free_config_params and krb5_free_context.

git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@10225 dc483132-0cff-0310-8789-dd5450dbe970

src/lib/kadm5/clnt/ChangeLog
src/lib/kadm5/clnt/client_init.c

index eeaa2a121e1b9edd7c99e5b82664561420d65ece..e3d65e2dc1f4c0238d519ff30a19904d72e1931c 100644 (file)
@@ -1,3 +1,8 @@
+Mon Oct 13 10:55:02 1997  Ezra Peisach  <epeisach@mit.edu>
+
+       * client_init.c (kadm5_destroy): Free handle->lhandle field, call
+        kadm5_free_config_params and krb5_free_context.
+
 Tue Jul  1 02:34:46 1997  Tom Yu  <tlyu@mit.edu>
 
        * client_principal.c, client_rpc.c: Add support for setv4key.
index d6404465e8837a508c168bbb4e1547218bc2594a..43859a494b89aec10695dd5929b3419cf26e1345 100644 (file)
@@ -220,11 +220,11 @@ static kadm5_ret_t _kadm5_init_any(char *client_name,
          return KADM5_BAD_CLIENT_PARAMS;
      }
                        
-     if (code = kadm5_get_config_params(handle->context,
+     if ((code = kadm5_get_config_params(handle->context,
                                        DEFAULT_PROFILE_PATH,
                                        "KRB5_CONFIG",
                                        params_in,
-                                       &handle->params)) {
+                                       &handle->params))) {
          krb5_free_context(handle->context);
          free(handle);
          return(code);
@@ -530,6 +530,11 @@ kadm5_destroy(void *server_handle)
          AUTH_DESTROY(handle->clnt->cl_auth);
      if (handle->clnt)
          clnt_destroy(handle->clnt);
+     if (handle->lhandle)
+          free (handle->lhandle);
+
+     kadm5_free_config_params(handle->context, &handle->params);
+     krb5_free_context(handle->context);
 
      handle->magic_number = 0;
      free(handle);