summaryrefslogtreecommitdiffstats
path: root/crypto
diff options
context:
space:
mode:
authorAndy Polyakov <appro@openssl.org>2017-04-07 22:30:13 +0200
committerAndy Polyakov <appro@openssl.org>2017-04-08 20:35:34 +0200
commit70b9063cd24904fd3d0b83173c51fdcf34085967 (patch)
tree2bb57617cf3c6a8836586782f3d612f3b9919f84 /crypto
parent00eae742694a87978e5e07593109f3cd895b4bc8 (diff)
e_os.h: omit PRIu64.
PRIu64 is error-prone with BIO_printf, so introduce and stick to custom platform-neutral macro. 'll' allows to print 64-bit values on *all* supported platforms, but it's problematic with -Wformat -Werror. Hence use 'l' in identifiable LP64 cases. Reviewed-by: Richard Levitte <levitte@openssl.org> (Merged from https://github.com/openssl/openssl/pull/3148)
Diffstat (limited to 'crypto')
-rw-r--r--crypto/asn1/x_int64.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/crypto/asn1/x_int64.c b/crypto/asn1/x_int64.c
index d180a3bb3a..e0520ffa2d 100644
--- a/crypto/asn1/x_int64.c
+++ b/crypto/asn1/x_int64.c
@@ -79,8 +79,8 @@ static int uint64_print(BIO *out, ASN1_VALUE **pval, const ASN1_ITEM *it,
int indent, const ASN1_PCTX *pctx)
{
if ((it->size & INTxx_FLAG_SIGNED) == INTxx_FLAG_SIGNED)
- return BIO_printf(out, "%jd\n", *(int64_t *)pval);
- return BIO_printf(out, "%ju\n", *(uint64_t *)pval);
+ return BIO_printf(out, "%"BIO_PRI64"d\n", *(int64_t *)pval);
+ return BIO_printf(out, "%"BIO_PRI64"u\n", *(uint64_t *)pval);
}
/* 32-bit variants */