Alternate fix for ../test/recipes/80-test_ssl_old.t with no-ec
[openssl.git] / test / packettest.c
index 98b9ec4889339e70ec5d47b1aae365e18d8fbf27..716dec303d4488b26883ad4a086821d0d6a887ae 100644 (file)
@@ -352,7 +352,7 @@ static int test_PACKET_get_length_prefixed_1(void)
     unsigned int i;
     PACKET pkt, short_pkt, subpkt = {0};
 
-    buf1[0] = len;
+    buf1[0] = (unsigned char)len;
     for (i = 1; i < BUF_LEN; i++)
         buf1[i] = (i * 2) & 0xff;
 
@@ -422,7 +422,7 @@ static int test_PACKET_as_length_prefixed_1(void)
     unsigned int i;
     PACKET pkt, exact_pkt, subpkt = {0};
 
-    buf1[0] = len;
+    buf1[0] = (unsigned char)len;
     for (i = 1; i < BUF_LEN; i++)
         buf1[i] = (i * 2) & 0xff;