]> git.ipfire.org Git - thirdparty/curl.git/commitdiff
easy_reset: fix dohfor_mid member
authorStefan Eissing <stefan@eissing.org>
Tue, 15 Apr 2025 09:27:12 +0000 (11:27 +0200)
committerDaniel Stenberg <daniel@haxx.se>
Tue, 15 Apr 2025 15:31:17 +0000 (17:31 +0200)
On an easy reset, the dohfor_mid must be reset to -1.

Reported-by: epicmkirzinger on github
Fixes #17052
Closes #17058

lib/url.c

index d94a29375e6b077b3b02fd13ee6f9db644be679e..39d72ac70a4570db3d089d60048714dbb4deedfa 100644 (file)
--- a/lib/url.c
+++ b/lib/url.c
@@ -366,6 +366,10 @@ CURLcode Curl_init_userdefined(struct Curl_easy *data)
   set->postfieldsize = -1;   /* unknown size */
   set->maxredirs = 30;       /* sensible default */
 
+#ifndef CURL_DISABLE_DOH
+  set->dohfor_mid  = -1;
+#endif
+
   set->method = HTTPREQ_GET; /* Default HTTP request */
 #ifndef CURL_DISABLE_RTSP
   set->rtspreq = RTSPREQ_OPTIONS; /* Default RTSP request */