changeset 5458:156e65ca910f

[gaim-migrate @ 5846] Fixed a memleak. committer: Tailor Script <tailor@pidgin.im>
author Christian Hammond <chipx86@chipx86.com>
date Tue, 20 May 2003 08:37:39 +0000
parents c8c290021b7b
children 1c5771e18492
files src/prefs.c
diffstat 1 files changed, 3 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/src/prefs.c	Tue May 20 04:38:40 2003 +0000
+++ b/src/prefs.c	Tue May 20 08:37:39 2003 +0000
@@ -133,13 +133,15 @@
 	struct gaim_pref *parent;
 	struct gaim_pref *me;
 	struct gaim_pref *sibling;
-	char *my_name = g_path_get_basename(name);
+	char *my_name;
 
 	parent = find_pref_parent(name);
 
 	if(!parent)
 		return NULL;
 
+	my_name = g_path_get_basename(name);
+
 	for(sibling = parent->first_child; sibling; sibling = sibling->sibling) {
 		if(!strcmp(sibling->name, my_name)) {
 			g_free(my_name);