]> git.ipfire.org Git - thirdparty/curl.git/commitdiff
vtls: fix failf() format argument type for %.*s handling
authorDaniel Stenberg <daniel@haxx.se>
Mon, 6 Feb 2023 16:50:09 +0000 (17:50 +0100)
committerDaniel Stenberg <daniel@haxx.se>
Mon, 6 Feb 2023 22:41:21 +0000 (23:41 +0100)
Reported by Coverity

Closes #10422

lib/vtls/vtls.c

index 604caccf71abefb962a337fe9679cd96a0f0fa32..e8ae3c05ffa6608b1ad5ff296fad299b78240977 100644 (file)
@@ -2022,7 +2022,7 @@ CURLcode Curl_alpn_set_negotiated(struct Curl_cfilter *cf,
 #endif
     else {
       cf->conn->alpn = CURL_HTTP_VERSION_NONE;
-      failf(data, "unsupported ALPN protocol: '%.*s'", proto_len, proto);
+      failf(data, "unsupported ALPN protocol: '%.*s'", (int)proto_len, proto);
       /* TODO: do we want to fail this? Previous code just ignored it and
        * some vtls backends even ignore the return code of this function. */
       /* return CURLE_NOT_BUILT_IN; */