From aab5258b7adcc0b84c7bf8bb2f0f2fee7f80c59f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Manuel=20P=C3=A9gouri=C3=A9-Gonnard?= Date: Tue, 18 Jan 2022 09:30:51 +0100 Subject: [PATCH] Avoid using %zu, not supported everywhere yet. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Manuel Pégourié-Gonnard --- programs/psa/aead_cipher_psa.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/programs/psa/aead_cipher_psa.c b/programs/psa/aead_cipher_psa.c index 52f33c79d..9af50eaa5 100644 --- a/programs/psa/aead_cipher_psa.c +++ b/programs/psa/aead_cipher_psa.c @@ -141,7 +141,7 @@ static void cipher_info( const mbedtls_cipher_context_t *ctx, size_t tag_len ) : mode == MBEDTLS_MODE_CHACHAPOLY ? "ChachaPoly" : "???"; - printf( "cipher: %s, %d, %s, %zu\n", ciph, key_bits, mode_str, tag_len ); + printf( "cipher: %s, %d, %s, %u\n", ciph, key_bits, mode_str, (unsigned) tag_len ); } static int cipher_encrypt( mbedtls_cipher_context_t *ctx, size_t tag_len, @@ -272,7 +272,8 @@ static void aead_info( psa_key_id_t key, psa_algorithm_t alg ) : base_alg == PSA_ALG_CHACHA20_POLY1305 ? "ChachaPoly" : "???"; - printf( "aead : %s, %zu, %s, %zu\n", type_str, key_bits, base_str, tag_len ); + printf( "aead : %s, %u, %s, %u\n", + type_str, (unsigned) key_bits, base_str, (unsigned) tag_len ); } static int aead_encrypt( psa_key_id_t key, psa_algorithm_t alg,