summaryrefslogtreecommitdiff
path: root/ssl/ssl_txt.c
diff options
context:
space:
mode:
authorJ.W. Jagersma <jwjagersma@gmail.com>2022-10-01 18:41:44 +0200
committerHugo Landau <hlandau@openssl.org>2022-11-14 07:47:53 +0000
commit1555c86e5f7e3c46b4f696ed665c2f988976b81f (patch)
treef7f131a40e8f3f4ea2e24206ad7762a00fd7f0c0 /ssl/ssl_txt.c
parent43086b1bd48958ce95fadba8459ad88675da4fdf (diff)
downloadopenssl-new-1555c86e5f7e3c46b4f696ed665c2f988976b81f.tar.gz
Cast values to match printf format strings.
For some reason djgpp uses '(unsigned) long int' for (u)int32_t. This causes errors with -Werror=format, even though these types are in practice identical. Obvious solution: cast to the types indicated by the format string. For asn1_time_test.c I changed the format string to %lli since time_t may be 'long long' some platforms. Reviewed-by: Hugo Landau <hlandau@openssl.org> Reviewed-by: Tomas Mraz <tomas@openssl.org> (Merged from https://github.com/openssl/openssl/pull/19322)
Diffstat (limited to 'ssl/ssl_txt.c')
-rw-r--r--ssl/ssl_txt.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/ssl/ssl_txt.c b/ssl/ssl_txt.c
index 68f15d6182..9e9c2e10ec 100644
--- a/ssl/ssl_txt.c
+++ b/ssl/ssl_txt.c
@@ -153,7 +153,7 @@ int SSL_SESSION_print(BIO *bp, const SSL_SESSION *x)
if (istls13) {
if (BIO_printf(bp, " Max Early Data: %u\n",
- x->ext.max_early_data) <= 0)
+ (unsigned int)x->ext.max_early_data) <= 0)
goto err;
}