changeset 6706:854a435d2cc3

[gaim-migrate @ 7232] Don't crash when trying to get the parent group of a buddy that is not yet in a group. committer: Tailor Script <tailor@pidgin.im>
author Christian Hammond <chipx86@chipx86.com>
date Tue, 02 Sep 2003 06:05:37 +0000
parents cebd49f42b56
children 1194d9673b99
files src/blist.c
diffstat 1 files changed, 4 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/src/blist.c	Tue Sep 02 05:12:45 2003 +0000
+++ b/src/blist.c	Tue Sep 02 06:05:37 2003 +0000
@@ -1131,6 +1131,10 @@
 {
 	if (!buddy)
 		return NULL;
+
+	if (((GaimBlistNode *)buddy)->parent == NULL)
+		return NULL;
+
 	return (GaimGroup *)(((GaimBlistNode*)buddy)->parent->parent);
 }