changeset 15921:6a5089fafd19

Fix a small tooltip-related memleak
author Mark Doliner <mark@kingant.net>
date Sun, 25 Mar 2007 07:34:51 +0000
parents f33506aa71af
children d7feace39800
files libpurple/protocols/yahoo/yahoo_packet.c pidgin/gtkblist.c
diffstat 2 files changed, 2 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/libpurple/protocols/yahoo/yahoo_packet.c	Sun Mar 25 07:20:01 2007 +0000
+++ b/libpurple/protocols/yahoo/yahoo_packet.c	Sun Mar 25 07:34:51 2007 +0000
@@ -161,6 +161,7 @@
 		}
 
 		if (accept) {
+			/* TODO: strstr() should not be used here because data isn't NULL terminated */
 			delimiter = (const guchar *)strstr((char *)&data[pos], "\xc0\x80");
 			if (delimiter == NULL)
 			{
--- a/pidgin/gtkblist.c	Sun Mar 25 07:20:01 2007 +0000
+++ b/pidgin/gtkblist.c	Sun Mar 25 07:34:51 2007 +0000
@@ -2279,6 +2279,7 @@
 	else
 		tmp = g_markup_escape_text(purple_chat_get_name((PurpleChat*)node), -1);
 	node_name = g_strdup_printf("<span size='x-large' weight='bold'>%s</span>", tmp);
+	g_free(tmp);
 
 	pango_layout_set_markup(td->layout, tooltip_text, -1);
 	pango_layout_set_wrap(td->layout, PANGO_WRAP_WORD);