1
0
mirror of https://github.com/moparisthebest/curl synced 2024-12-24 17:18:48 -05:00

ngtcp2: use ngtcp2_version() to get the run-time version

... which of course doesn't have to be the same used at build-time.

Function just recently merged in ngtcp2.
This commit is contained in:
Daniel Stenberg 2019-08-19 23:04:45 +02:00
parent 349c3f5a08
commit 1a0dc6f6a3
No known key found for this signature in database
GPG Key ID: 5CC908FDB71E12C2

View File

@ -1149,8 +1149,9 @@ CURLcode Curl_quic_connect(struct connectdata *conn,
*/ */
int Curl_quic_ver(char *p, size_t len) int Curl_quic_ver(char *p, size_t len)
{ {
ngtcp2_info *ng2 = ngtcp2_version(0);
return msnprintf(p, len, " ngtcp2/%s nghttp3/%s", return msnprintf(p, len, " ngtcp2/%s nghttp3/%s",
NGTCP2_VERSION, NGHTTP3_VERSION); ng2->version_str, NGHTTP3_VERSION);
} }
static int ng_getsock(struct connectdata *conn, curl_socket_t *socks) static int ng_getsock(struct connectdata *conn, curl_socket_t *socks)