mirror of
https://github.com/curl/curl.git
synced 2026-04-15 04:11:41 +03:00
free() allocated memory when the ares search can't be made
This commit is contained in:
parent
a5360255ba
commit
c2e8ba0fba
1 changed files with 5 additions and 0 deletions
|
|
@ -124,7 +124,12 @@ void ares_search(ares_channel channel, const char *name, int dnsclass,
|
|||
free(s);
|
||||
}
|
||||
else
|
||||
{
|
||||
/* failed, free the malloc()ed memory */
|
||||
free(squery->name);
|
||||
free(squery);
|
||||
callback(arg, status, NULL, 0);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue