From: Daniel Gustafsson Date: Wed, 11 May 2022 08:38:08 +0000 (+0200) Subject: x509asn1: mark msnprintf return as unchecked X-Git-Tag: curl-7_84_0~213 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=bcf03dd2131d1513677ff684cd06a9ed71f9ca43;p=thirdparty%2Fcurl.git 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 --- 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; }