From: Daniel Stenberg Date: Thu, 28 Apr 2022 15:11:50 +0000 (+0200) Subject: mbedtls: fix compile when h2-enabled X-Git-Tag: curl-7_83_1~61 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=6eb7fb37d901ed1e4ce07cbd628ee11bf02db1f3;p=thirdparty%2Fcurl.git mbedtls: fix compile when h2-enabled Fixes #8766 Reported-by: LigH-de on github Closes #8768 --- diff --git a/lib/vtls/mbedtls.c b/lib/vtls/mbedtls.c index 64f57c5d83..5f9b87e6b7 100644 --- a/lib/vtls/mbedtls.c +++ b/lib/vtls/mbedtls.c @@ -815,8 +815,8 @@ mbed_connect_step2(struct Curl_easy *data, struct connectdata *conn, if(next_protocol) { infof(data, VTLS_INFOF_ALPN_ACCEPTED_1STR, next_protocol); #ifdef USE_HTTP2 - if(!strncmp(next_protocol, ALPN_H2, ALPN_H2_LEN) && - !next_protocol[ALPN_H2_LEN]) { + if(!strncmp(next_protocol, ALPN_H2, ALPN_H2_LENGTH) && + !next_protocol[ALPN_H2_LENGTH]) { conn->negnpn = CURL_HTTP_VERSION_2; } else