changeset 6779:f5c483cdd1d8

[gaim-migrate @ 7317] more memleak fixes. ChipX86 will probably revert these, since I probably did it wrong ;-) committer: Tailor Script <tailor@pidgin.im>
author Nathan Walp <nwalp@pidgin.im>
date Sun, 07 Sep 2003 16:22:58 +0000
parents b8bc8dd411cc
children e9a730ad5a3c
files src/protocols/msn/notification.c src/protocols/msn/servconn.c src/protocols/msn/session.c
diffstat 3 files changed, 16 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/src/protocols/msn/notification.c	Sun Sep 07 15:55:28 2003 +0000
+++ b/src/protocols/msn/notification.c	Sun Sep 07 16:22:58 2003 +0000
@@ -349,11 +349,14 @@
 
 	if ((s = gaim_ssl_write(gsc, request_str, strlen(request_str))) <= 0)
 	{
+		g_free(request_str);
 		gaim_connection_error(gc, _("Unable to write to MSN Nexus server."));
 
 		return;
 	}
 
+	g_free(request_str);
+
 	if ((s = msn_ssl_read(gsc, &buffer)) <= 0)
 	{
 		gaim_connection_error(gc, _("Unable to read from MSN Nexus server."));
@@ -507,10 +510,12 @@
 
 	if ((s = gaim_ssl_write(gsc, request_str, strlen(request_str))) <= 0)
 	{
+		g_free(request_str);
 		gaim_connection_error(gc, _("Unable to write to MSN Nexus server."));
 		return;
 	}
 
+	g_free(request_str);
 	g_free(session->ssl_url);
 	session->ssl_url = NULL;
 
@@ -636,6 +641,8 @@
 			}
 		}
 
+		g_free(challenge_data);
+
 #if 0
 		passport_str = g_strdup(msn_url_decode(params[3]));
 
--- a/src/protocols/msn/servconn.c	Sun Sep 07 15:55:28 2003 +0000
+++ b/src/protocols/msn/servconn.c	Sun Sep 07 16:22:58 2003 +0000
@@ -278,6 +278,9 @@
 	if (servconn->server != NULL)
 		g_free(servconn->server);
 
+	g_hash_table_destroy(servconn->commands);
+	g_hash_table_destroy(servconn->msg_types);
+
 	g_free(servconn);
 }
 
--- a/src/protocols/msn/session.c	Sun Sep 07 15:55:28 2003 +0000
+++ b/src/protocols/msn/session.c	Sun Sep 07 16:22:58 2003 +0000
@@ -59,6 +59,12 @@
 	if (session->dispatch_server != NULL)
 		g_free(session->dispatch_server);
 
+	if (session->ssl_login_path != NULL)
+		g_free(session->ssl_login_path);
+
+	if (session->ssl_login_host != NULL)
+		g_free(session->ssl_login_host);
+
 	while (session->switches != NULL)
 		msn_switchboard_destroy(session->switches->data);