mirror of
https://frontier.innolan.net/rainlance/c-ares.git
synced 2025-10-05 16:50:11 +00:00
Do not leak rr_name on failures inside ares_parse_ns_reply
This commit is contained in:
@ -103,6 +103,7 @@ int ares_parse_ns_reply( const unsigned char* abuf, int alen,
|
||||
if ( aptr + RRFIXEDSZ > abuf + alen )
|
||||
{
|
||||
status = ARES_EBADRESP;
|
||||
free(rr_name);
|
||||
break;
|
||||
}
|
||||
rr_type = DNS_RR_TYPE( aptr );
|
||||
@ -117,6 +118,7 @@ int ares_parse_ns_reply( const unsigned char* abuf, int alen,
|
||||
&len);
|
||||
if ( status != ARES_SUCCESS )
|
||||
{
|
||||
free(rr_name);
|
||||
break;
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user