asyn-ares: fix memory leak

Closes #16107
This commit is contained in:
Dexter Gerig 2025-01-27 22:45:46 -06:00 committed by Daniel Stenberg
parent afb3fd7112
commit f25a807a7d
No known key found for this signature in database
GPG Key ID: 5CC908FDB71E12C2

View File

@ -435,8 +435,9 @@ CURLcode Curl_resolver_is_resolved(struct Curl_easy *data,
struct Curl_https_rrinfo *lhrr =
Curl_memdup(&res->hinfo, sizeof(struct Curl_https_rrinfo));
if(!lhrr)
return CURLE_OUT_OF_MEMORY;
(*dns)->hinfo = lhrr;
result = CURLE_OUT_OF_MEMORY;
else
(*dns)->hinfo = lhrr;
}
#endif
}