← Commit list

69f3a36bcb

Stefan Eissing
Stefan Eissing
2026-04-23
SUCCESS Duration: 231s

Subject

doh: remove conn->bits.doh

Binary

No binary (build failed)

Architecture & Compiler Flags

Architecture: x86_64-linux-gnu Compiler: gcc (Ubuntu 11.4.0-1ubuntu1~22.04.3) 11.4.0

—

Build Log

(log yok)

Commit Diff GitHub →

lib/doh.c+3 -4
@@ -457,14 +457,14 @@ CURLcode Curl_doh(struct Curl_easy *data,
{
CURLcode result = CURLE_OK;
struct doh_probes *dohp = NULL;
- struct connectdata *conn = data->conn;
size_t i;
- DEBUGASSERT(conn);
DEBUGASSERT(!async->doh);
DEBUGASSERT(async->hostname[0]);
- if(async->doh)
+ if(async->doh) {
+ DEBUGASSERT(0); /* should not happen */
Curl_doh_cleanup(data, async);
+ }
/* start clean, consider allocating this struct on demand */
async->doh = dohp = curlx_calloc(1, sizeof(struct doh_probes));
@@ -476,7 +476,6 @@ CURLcode Curl_doh(struct Curl_easy *data,
curlx_dyn_init(&dohp->probe_resp[i].body, DYN_DOH_RESPONSE);
}
- conn->bits.doh = TRUE;
dohp->host = async->hostname;
dohp->port = async->port;
/* We are making sub easy handles and want to be called back when
lib/hostip.c+2 -4
@@ -424,7 +424,7 @@ static CURLcode hostip_resolv_take_result(struct Curl_easy *data,
return CURLE_FAILED_INIT;
#ifndef CURL_DISABLE_DOH
- if(data->conn->bits.doh)
+ if(async->doh)
result = Curl_doh_take_result(data, async, pdns);
else
#endif
@@ -670,9 +670,7 @@ static CURLcode hostip_resolv(struct Curl_easy *data,
*presolv_id = 0;
*pdns = NULL;
-#ifndef CURL_DISABLE_DOH
- data->conn->bits.doh = FALSE; /* default is not */
-#else
+#ifdef CURL_DISABLE_DOH
(void)allowDOH;
#endif
lib/urldata.h+0 -3
@@ -295,9 +295,6 @@ struct ConnectBits {
BIT(multiplex); /* connection is multiplexed */
BIT(tcp_fastopen); /* use TCP Fast Open */
BIT(tls_enable_alpn); /* TLS ALPN extension? */
-#ifndef CURL_DISABLE_DOH
- BIT(doh);
-#endif
#ifdef USE_UNIX_SOCKETS
BIT(abstract_unix_socket);
#endif