From bc7718a5d0779b287b82853bc410a0b7dda86f94 Mon Sep 17 00:00:00 2001 From: Viktor Szakats Date: Fri, 18 Jul 2025 20:57:33 +0200 Subject: [PATCH] fix trc for !http + http3 lib/curl_trc.c:486:6: error: use of undeclared identifier 'Curl_cft_http3' 486 | { &Curl_cft_http3, TRC_CT_PROTOCOL }, | ^ lib/curl_trc.c:497:18: error: invalid application of 'sizeof' to an incomplete type 'struct trc_cft_def[]' 497 | for(i = 0; i < CURL_ARRAYSIZE(trc_cfts); ++i) { | ^~~~~~~~~~~~~~~~~~~~~~~~ lib/curl_setup.h:957:34: note: expanded from macro 'CURL_ARRAYSIZE' 957 | #define CURL_ARRAYSIZE(A) (sizeof(A)/sizeof((A)[0])) | ^~~ In file included from _buildroulette/bld/lib/CMakeFiles/libcurl_shared.dir/Unity/unity_1_c.c:13: lib/curl_trc.c:515:18: error: invalid application of 'sizeof' to an incomplete type 'struct trc_cft_def[]' 515 | for(i = 0; i < CURL_ARRAYSIZE(trc_cfts); ++i) { | ^~~~~~~~~~~~~~~~~~~~~~~~ lib/curl_setup.h:957:34: note: expanded from macro 'CURL_ARRAYSIZE' 957 | #define CURL_ARRAYSIZE(A) (sizeof(A)/sizeof((A)[0])) | ^~~ 3 errors generated. options='-DCURL_DISABLE_DIGEST_AUTH=ON -DCURL_DISABLE_DOH=ON -DCURL_DISABLE_HTTP=ON -DCURL_DISABLE_IMAP=ON -DCURL_DISABLE_KERBEROS_AUTH=ON -DCURL_DISABLE_PARSEDATE=ON -DCURL_DISABLE_SHA512_256=ON -DCURL_DISABLE_SHUFFLE_DNS=ON -DENABLE_CURLDEBUG=OFF -DCURL_USE_OPENSSL=ON -DUSE_OPENSSL_QUIC=ON' --- lib/curl_trc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/curl_trc.c b/lib/curl_trc.c index 9a1f706d40..4bcd386626 100644 --- a/lib/curl_trc.c +++ b/lib/curl_trc.c @@ -482,7 +482,7 @@ static struct trc_cft_def trc_cfts[] = { { &Curl_cft_haproxy, TRC_CT_PROXY }, { &Curl_cft_socks_proxy, TRC_CT_PROXY }, #endif /* !CURL_DISABLE_PROXY */ -#ifdef USE_HTTP3 +#if !defined(CURL_DISABLE_HTTP) && defined(USE_HTTP3) { &Curl_cft_http3, TRC_CT_PROTOCOL }, #endif #if !defined(CURL_DISABLE_HTTP)