[glib-networking/mcatanzaro/session-resumption: 8/18] gnutls: fix session data leak
- From: Michael Catanzaro <mcatanzaro src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [glib-networking/mcatanzaro/session-resumption: 8/18] gnutls: fix session data leak
- Date: Thu, 14 Nov 2019 23:25:54 +0000 (UTC)
commit 7bfc6a73868f199c6612b7763e4aeecdb258a7b4
Author: Michael Catanzaro <mcatanzaro gnome org>
Date: Tue Oct 1 19:19:15 2019 -0500
gnutls: fix session data leak
tls/gnutls/gtlsclientconnection-gnutls.c | 1 +
1 file changed, 1 insertion(+)
---
diff --git a/tls/gnutls/gtlsclientconnection-gnutls.c b/tls/gnutls/gtlsclientconnection-gnutls.c
index 86a4f19..c62c8bb 100644
--- a/tls/gnutls/gtlsclientconnection-gnutls.c
+++ b/tls/gnutls/gtlsclientconnection-gnutls.c
@@ -467,6 +467,7 @@ g_tls_client_connection_gnutls_complete_handshake (GTlsConnectionBase *tls,
if (gnutls_session_get_data2 (g_tls_connection_gnutls_get_session (G_TLS_CONNECTION_GNUTLS (tls)),
&session_datum) == 0)
{
+ g_clear_pointer (&gnutls->session_data, g_bytes_unref);
gnutls->session_data = g_bytes_new_with_free_func (session_datum.data,
session_datum.size,
(GDestroyNotify)gnutls_free,
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]