Commit 7dd19d09 authored by Pekka Pessi's avatar Pekka Pessi

tport_tls.c: avoid free(NULL)

darcs-hash:20080507145916-db55f-b4b835cecb38ab3818e7a58981034f975cf35818.gz
parent 8e82e6bc
......@@ -299,7 +299,9 @@ void tls_free(tls_t *tls)
BIO_free(tls->bio_con);
for (k = 0; k < TLS_MAX_HOSTS; k++)
free(tls->hosts[k]), tls->hosts[k] = NULL;
if (tls->hosts[k]) {
free(tls->hosts[k]), tls->hosts[k] = NULL;
}
free(tls);
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment