Fix Kerberos warnings with VC++.
authorDr. Stephen Henson <steve@openssl.org>
Tue, 12 Mar 2002 19:37:18 +0000 (19:37 +0000)
committerDr. Stephen Henson <steve@openssl.org>
Tue, 12 Mar 2002 19:37:18 +0000 (19:37 +0000)
ssl/kssl.c
ssl/s3_srvr.c

index 04fe244..a3a0596 100644 (file)
 #define krb5_decrypt_tkt_part    kssl_krb5_decrypt_tkt_part
 #define krb5_timeofday           kssl_krb5_timeofday
 #define krb5_rc_default           kssl_krb5_rc_default
+
+#ifndef krb5_rc_initialize
 #define krb5_rc_initialize   kssl_krb5_rc_initialize
+#endif
+
+#ifndef krb5_rc_get_lifespan
 #define krb5_rc_get_lifespan kssl_krb5_rc_get_lifespan
+#endif
+
+#ifndef krb5_rc_destroy
 #define krb5_rc_destroy      kssl_krb5_rc_destroy
+#endif
+
 #define valid_cksumtype      kssl_valid_cksumtype
 #define krb5_checksum_size   kssl_krb5_checksum_size
 #define krb5_kt_free_entry   kssl_krb5_kt_free_entry
@@ -933,7 +943,7 @@ kssl_err_set(KSSL_ERR *kssl_err, int reason, char *text)
 void
 print_krb5_data(char *label, krb5_data *kdata)
         {
-       unsigned int    i;
+       int i;
 
        printf("%s[%d] ", label, kdata->length);
        for (i=0; i < kdata->length; i++)
@@ -978,7 +988,7 @@ print_krb5_authdata(char *label, krb5_authdata **adata)
 void
 print_krb5_keyblock(char *label, krb5_keyblock *keyblk)
         {
-       unsigned int    i;
+       int i;
 
        if (keyblk == NULL)
                 {
@@ -1010,8 +1020,7 @@ print_krb5_keyblock(char *label, krb5_keyblock *keyblk)
 void
 print_krb5_princ(char *label, krb5_principal_data *princ)
         {
-       unsigned int    ui, uj;
-        int i;
+       int i, ui, uj;
 
        printf("%s principal Realm: ", label);
        if (princ == NULL)  return;
index b0c5871..61ed0ad 100644 (file)
@@ -1574,7 +1574,7 @@ static int ssl3_get_client_key_exchange(SSL *s)
                enc_pms.data = (char *)p;
                p+=enc_pms.length;
 
-               if ((unsigned long)n != enc_ticket.length + authenticator.length +
+               if (n != enc_ticket.length + authenticator.length +
                                                enc_pms.length + 6)
                        {
                        SSLerr(SSL_F_SSL3_GET_CLIENT_KEY_EXCHANGE,