* walk_rtree.c (krb5_walk_realm_tree): Do not try to free const char *
authorEzra Peisach <epeisach@mit.edu>
Wed, 8 Aug 2001 16:31:02 +0000 (16:31 +0000)
committerEzra Peisach <epeisach@mit.edu>
Wed, 8 Aug 2001 16:31:02 +0000 (16:31 +0000)
* mk_safe.c (krb5_mk_safe_basic): Do not declare local_addr and
remote_addr const and then cast the attribute away.

* mk_req_ext.c (krb5_generate_authenticator): Static function -
remove const attribute from cksum pointer.

* gc_via_tkt.c (krb5_get_cred_via_tkt): Cast unsigned integer
krb5_error error_value to signed before adding
ERROR_TABLE_BASE_krb5.

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

src/lib/krb5/krb/ChangeLog
src/lib/krb5/krb/gc_via_tkt.c
src/lib/krb5/krb/mk_req_ext.c
src/lib/krb5/krb/mk_safe.c
src/lib/krb5/krb/walk_rtree.c

index 223e7844d12e79faf9375af4b7268b74d27b6422..4009fb29ad151df17e09c60ddb678f39aec46edd 100644 (file)
@@ -1,3 +1,17 @@
+2001-08-08    <epeisach@mit.edu>
+
+       * walk_rtree.c (krb5_walk_realm_tree): Do not try to free const char *.
+
+       * mk_safe.c (krb5_mk_safe_basic): Do not declare local_addr and
+       remote_addr const and then cast the attribute away.
+
+       * mk_req_ext.c (krb5_generate_authenticator): Static function -
+       remove const attribute from cksum pointer.
+
+       * gc_via_tkt.c (krb5_get_cred_via_tkt): Cast unsigned integer
+       krb5_error error_value to signed before adding
+       ERROR_TABLE_BASE_krb5.
+
 2001-07-31  Ken Raeburn  <raeburn@mit.edu>
 
        * chk_trans.c (krb5_check_transited_list): Pointer args now point
index 20098781c2f12d191e7c79b3bccf21d25cba8de4..6eda0ce2cd8de578a6ab6f56d738a6069e0a4603 100644 (file)
@@ -179,7 +179,7 @@ krb5_get_cred_via_tkt (context, tkt, kdcoptions, address, in_cred, out_cred)
        if (retval)                     /* neither proper reply nor error! */
            goto error_4;
 
-       retval = err_reply->error + ERROR_TABLE_BASE_krb5;
+       retval = (krb5_error_code) err_reply->error + ERROR_TABLE_BASE_krb5;
 
        krb5_free_error(context, err_reply);
        goto error_4;
index 88daab56704bd2d734af8da6004204e412a30260..7bb8781eef551f5e4b042afe3c27ed37b16231c0 100644 (file)
@@ -67,7 +67,7 @@
 static krb5_error_code 
 krb5_generate_authenticator PROTOTYPE((krb5_context,
                                       krb5_authenticator *, krb5_principal,
-                                      const krb5_checksum *, krb5_keyblock *,
+                                      krb5_checksum *, krb5_keyblock *,
                                       krb5_int32, krb5_authdata ** ));
 
 KRB5_DLLIMP krb5_error_code KRB5_CALLCONV
@@ -230,7 +230,7 @@ krb5_generate_authenticator(context, authent, client, cksum, key, seq_number, au
     krb5_context context;
     krb5_authenticator *authent;
     krb5_principal client;
-    const krb5_checksum *cksum;
+    krb5_checksum *cksum;
     krb5_keyblock *key;
     krb5_int32 seq_number;
     krb5_authdata **authorization;
@@ -238,7 +238,7 @@ krb5_generate_authenticator(context, authent, client, cksum, key, seq_number, au
     krb5_error_code retval;
     
     authent->client = client;
-    authent->checksum = (krb5_checksum *)cksum;
+    authent->checksum = cksum;
     if (key) {
        retval = krb5_copy_keyblock(context, key, &authent->subkey);
        if (retval)
index 063b3dbf44bb83b6a7f64e5a9968e7f69618cb63..dc636c7e932b3eeae7c35f38007240d5da3c659c 100644 (file)
@@ -53,8 +53,8 @@ krb5_mk_safe_basic(context, userdata, keyblock, replaydata, local_addr,
     const krb5_data    * userdata;
     const krb5_keyblock * keyblock;
     krb5_replay_data    * replaydata;
-    const krb5_address         * local_addr;
-    const krb5_address         * remote_addr;
+    krb5_address       * local_addr;
+    krb5_address       * remote_addr;
     const krb5_cksumtype  sumtype;
     krb5_data          * outbuf;
 {
index 399f5acab15935644ae6c5032d8f47c24da7191b..a3a7ee2bf953c947e02f8295a282d467cddbc3e8 100644 (file)
@@ -130,7 +130,8 @@ krb5_walk_realm_tree(context, client, server, tree, realm_branch_char)
     cap_names[2] = cap_server;
     cap_names[3] = 0;
     cap_code = profile_get_values(context->profile, cap_names, &cap_nodes);
-    krb5_xfree(cap_names[1]);    /* done with client string */
+    krb5_xfree(cap_client);  /* done with client string */
+    cap_names[1] = 0;
     if (cap_code == 0) {     /* found a path, so lets use it */
        links = 0;
        if (*cap_nodes[0] != '.') { /* a link of . means direct */
@@ -143,7 +144,8 @@ krb5_walk_realm_tree(context, client, server, tree, realm_branch_char)
        /* cleanup eaiser as well */
        links++;                /* count the null entry at end */
     } else {                   /* no path use hierarchical method */
-       krb5_xfree(cap_names[2]); /* failed, don't need server string */
+       krb5_xfree(cap_server); /* failed, don't need server string */
+       cap_names[2] = 0;
 #endif
        clen = client->length;
        slen = server->length;