* string_to_key.c (krb5_arcfour_string_to_key): Use size_t instead
authorEzra Peisach <epeisach@mit.edu>
Wed, 5 Dec 2001 23:30:25 +0000 (23:30 +0000)
committerEzra Peisach <epeisach@mit.edu>
Wed, 5 Dec 2001 23:30:25 +0000 (23:30 +0000)
        of int for local variable.
        (asctouni): Length argument now size_t instead of int.

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

src/lib/crypto/arcfour/ChangeLog
src/lib/crypto/arcfour/string_to_key.c

index fb5968b83e15cd6701cf322922858a003d8bd9f9..74647d521917e8c535c0b342ae237ab8fd8480cd 100644 (file)
@@ -1,3 +1,9 @@
+2001-12-05  Ezra Peisach  <epeisach@mit.edu>
+
+       * string_to_key.c (krb5_arcfour_string_to_key): Use size_t instead
+       of int for local variable.
+       (asctouni): Length argument now size_t instead of int.
+
 2001-11-07  Sam Hartman  <hartmans@mit.edu>
 
        * arcfour.c (krb5_arcfour_encrypt): Set output length
index 23bebca80f349f507f26a9086df5f3c4ce928880..a40f1ff347b38b6b81e00034b943c708c40cfc84 100644 (file)
@@ -2,7 +2,7 @@
 #include "rsa-md4.h"
 #include "arcfour-int.h"
 
-static void asctouni(unsigned char *unicode, unsigned char *ascii, int len)
+static void asctouni(unsigned char *unicode, unsigned char *ascii, size_t len)
 {
        int counter;
        for (counter=0;counter<len;counter++) {
@@ -18,7 +18,7 @@ krb5_arcfour_string_to_key(enc, string, salt, key)
        krb5_const krb5_data *salt;
        krb5_keyblock *key;
 {
-  int len,slen;
+  size_t len,slen;
   unsigned char *copystr;
   krb5_MD4_CTX md4_context;
   
@@ -37,7 +37,7 @@ krb5_arcfour_string_to_key(enc, string, salt, key)
   slen = ((string->length)>128)?128:string->length;
   len=(slen)*2;
 
-  copystr = malloc((size_t) len);
+  copystr = malloc(len);
   if (copystr == NULL)
     return ENOMEM;