From bcf03dd2131d1513677ff684cd06a9ed71f9ca43 Mon Sep 17 00:00:00 2001 From: Daniel Gustafsson Date: Wed, 11 May 2022 10:38:08 +0200 Subject: [PATCH] x509asn1: mark msnprintf return as unchecked We have lots of unchecked msnprintf calls, and this particular msnprintf call isn't more interesting than the others, but this one yields a Coverity warning so let's implicitly silence it. Going over the other invocations is probably a worthwhile project, but for now let's keep the static analyzers happy. Closes: #8831 Reviewed-by: Daniel Stenberg --- lib/vtls/x509asn1.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/vtls/x509asn1.c b/lib/vtls/x509asn1.c index dfb938621c..d6ee51250b 100644 --- a/lib/vtls/x509asn1.c +++ b/lib/vtls/x509asn1.c @@ -956,7 +956,7 @@ static int do_pubkey(struct Curl_easy *data, int certnum, infof(data, " ECC Public Key (%lu bits)", len); if(data->set.ssl.certinfo) { char q[sizeof(len) * 8 / 3 + 1]; - msnprintf(q, sizeof(q), "%lu", len); + (void)msnprintf(q, sizeof(q), "%lu", len); if(Curl_ssl_push_certinfo(data, certnum, "ECC Public Key", q)) return 1; }