mirror of https://github.com/getdnsapi/getdns.git
Fix: mem leak with gnutls
This commit is contained in:
parent
1067326bd0
commit
e17ed3938c
|
@ -767,6 +767,8 @@ getdns_return_t _getdns_tls_session_free(struct mem_funcs* mfs, _getdns_tls_sess
|
||||||
{
|
{
|
||||||
if (!s)
|
if (!s)
|
||||||
return GETDNS_RETURN_INVALID_PARAMETER;
|
return GETDNS_RETURN_INVALID_PARAMETER;
|
||||||
|
if (s->tls.data)
|
||||||
|
gnutls_free(s->tls.data);
|
||||||
GETDNS_FREE(*mfs, s);
|
GETDNS_FREE(*mfs, s);
|
||||||
return GETDNS_RETURN_GOOD;
|
return GETDNS_RETURN_GOOD;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue