Resolve warnings in VC-WIN32 build, which allows to add /WX.
[openssl.git] / ssl / statem / statem_lib.c
index 6db881630e8ac1e2291d73f1ee922dd3d96ccde8..cb1fb7d3dc81b326f4b3a8b1830c222c92dd0e5a 100644 (file)
@@ -2020,7 +2020,7 @@ int create_synthetic_message_hash(SSL *s)
 
     /* Inject the synthetic message_hash message */
     msghdr[0] = SSL3_MT_MESSAGE_HASH;
-    msghdr[SSL3_HM_HEADER_LENGTH - 1] = hashlen;
+    msghdr[SSL3_HM_HEADER_LENGTH - 1] = (unsigned char)hashlen;
     if (!ssl3_finish_mac(s, msghdr, SSL3_HM_HEADER_LENGTH)
             || !ssl3_finish_mac(s, hashval, hashlen)) {
         SSLerr(SSL_F_CREATE_SYNTHETIC_MESSAGE_HASH, ERR_R_INTERNAL_ERROR);