diff options
author | Daniel Stenberg <daniel@haxx.se> | 2007-04-21 21:32:31 +0000 |
---|---|---|
committer | Daniel Stenberg <daniel@haxx.se> | 2007-04-21 21:32:31 +0000 |
commit | cea9695bcfd157926670db57ba2495e1e3940730 (patch) | |
tree | e9707e1b34fc7581e86da53f0fb472f0f02245d7 /lib | |
parent | 92039629c7e72f9d792f963b5818630dce61c9cb (diff) |
Daniel Black filed bug #1704675 (http://curl.haxx.se/bug/view.cgi?id=1704675)
identifying a double-free problem in the SSL-dealing layer, telling GnuTLS to
free NULL credentials on closedown after a failure and a bad #ifdef for NSS
when closing down SSL.
Diffstat (limited to 'lib')
-rw-r--r-- | lib/gtls.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/gtls.c b/lib/gtls.c index 3def5d998..73461b9cc 100644 --- a/lib/gtls.c +++ b/lib/gtls.c @@ -502,7 +502,8 @@ static void close_one(struct connectdata *conn, gnutls_bye(conn->ssl[index].session, GNUTLS_SHUT_RDWR); gnutls_deinit(conn->ssl[index].session); } - gnutls_certificate_free_credentials(conn->ssl[index].cred); + if(conn->ssl[index].cred) + gnutls_certificate_free_credentials(conn->ssl[index].cred); } void Curl_gtls_close(struct connectdata *conn) |