diff --git a/library/aead_chacha20_poly1305.c b/library/aead_chacha20_poly1305.c index 2e07f1ed4..f00380c0b 100644 --- a/library/aead_chacha20_poly1305.c +++ b/library/aead_chacha20_poly1305.c @@ -421,7 +421,7 @@ static const unsigned char test_mac[1][16] = int mbedtls_aead_chacha20_poly1305_self_test( int verbose ) { - size_t i; + unsigned i; int result; unsigned char output[200]; unsigned char mac[16]; @@ -430,7 +430,7 @@ int mbedtls_aead_chacha20_poly1305_self_test( int verbose ) { if ( verbose != 0 ) { - mbedtls_printf( " ChaCha20-Poly1305 test %zu ", i ); + mbedtls_printf( " ChaCha20-Poly1305 test %u ", i ); } result = mbedtls_aead_chacha20_poly1305_crypt_and_mac( test_key[i], diff --git a/library/chacha20.c b/library/chacha20.c index 5d2c3e5bf..28133a675 100644 --- a/library/chacha20.c +++ b/library/chacha20.c @@ -554,14 +554,14 @@ static const size_t test_lengths[2] = int mbedtls_chacha20_self_test( int verbose ) { unsigned char output[381]; - size_t i; + unsigned i; int result; for ( i = 0U; i < 2U; i++ ) { if ( verbose != 0 ) { - mbedtls_printf( " ChaCha20 test %zu ", i ); + mbedtls_printf( " ChaCha20 test %u ", i ); } result = mbedtls_chacha20_crypt( test_keys[i], diff --git a/library/poly1305.c b/library/poly1305.c index 6acbc7fa5..5a096586d 100644 --- a/library/poly1305.c +++ b/library/poly1305.c @@ -485,14 +485,14 @@ static const unsigned char test_mac[2][16] = int mbedtls_poly1305_self_test( int verbose ) { unsigned char mac[16]; - size_t i; + unsigned i; int result; for ( i = 0U; i < 2U; i++ ) { if ( verbose != 0 ) { - mbedtls_printf( " Poly1305 test %zu ", i ); + mbedtls_printf( " Poly1305 test %u ", i ); } result = mbedtls_poly1305_mac( test_keys[i],