Integer type name change.
[silc.git] / lib / silccrypt / rc6.c
index 07997d8fa6dc956265484884367a5de3215520b4..2ca7c83cecdecd7a70d24552d894c5eb4e7cceb8 100644 (file)
@@ -37,6 +37,7 @@ Mean:          249 cycles =   103.0 mbits/sec
 */
 
 #include "silcincludes.h"
+#include "rc6_internal.h"
 #include "rc6.h"
 
 /* 
@@ -47,7 +48,7 @@ Mean:          249 cycles =   103.0 mbits/sec
 
 SILC_CIPHER_API_SET_KEY(rc6)
 {
-  uint32 k[8];
+  SilcUInt32 k[8];
 
   SILC_GET_WORD_KEY(key, k, keylen);
   rc6_set_key((RC6Context *)context, k, keylen);
@@ -68,7 +69,7 @@ SILC_CIPHER_API_SET_KEY_WITH_STRING(rc6)
 
 SILC_CIPHER_API_ENCRYPT_CBC(rc6)
 {
-  uint32 tiv[4];
+  SilcUInt32 tiv[4];
   int i;
 
   SILC_CBC_GET_IV(tiv, iv);
@@ -93,7 +94,7 @@ SILC_CIPHER_API_ENCRYPT_CBC(rc6)
 
 SILC_CIPHER_API_DECRYPT_CBC(rc6)
 {
-  uint32 tmp[4], tmp2[4], tiv[4];
+  SilcUInt32 tmp[4], tmp2[4], tiv[4];
   int i;
 
   SILC_CBC_GET_IV(tiv, iv);
@@ -151,7 +152,7 @@ u4byte *rc6_set_key(RC6Context *ctx,
 
         l[k] = in_key[k];
 
-    t = (key_len / 32) - 1; // t = (key_len / 32);
+    t = (key_len / 32) - 1; /* t = (key_len / 32); */
 
     a = b = i = j = 0;
 
@@ -159,8 +160,8 @@ u4byte *rc6_set_key(RC6Context *ctx,
     {   a = rotl(l_key[i] + a + b, 3); b += a;
         b = rotl(l[j] + b, b);
         l_key[i] = a; l[j] = b;
-        i = (i == 43 ? 0 : i + 1); // i = (i + 1) % 44;  
-        j = (j == t ? 0 : j + 1);  // j = (j + 1) % t;
+        i = (i == 43 ? 0 : i + 1); /* i = (i + 1) % 44; */
+        j = (j == t ? 0 : j + 1);  /* j = (j + 1) % t; */
     }
 
     return l_key;