changeset 15315:28051164843c

[gaim-migrate @ 18106] Do not crash trying to tag/attach NULL nodes. committer: Tailor Script <tailor@pidgin.im>
author Sadrul Habib Chowdhury <imadil@gmail.com>
date Thu, 11 Jan 2007 07:42:51 +0000
parents 4a4e1dfd8716
children a92c64f06995
files console/gntblist.c
diffstat 1 files changed, 5 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/console/gntblist.c	Thu Jan 11 07:26:28 2007 +0000
+++ b/console/gntblist.c	Thu Jan 11 07:42:51 2007 +0000
@@ -1002,6 +1002,8 @@
 gg_blist_toggle_tag_buddy(GaimBlistNode *node)
 {
 	GList *iter;
+	if (node == NULL)
+		return;
 	if (GAIM_BLIST_NODE_IS_CHAT(node) || GAIM_BLIST_NODE_IS_GROUP(node))
 		return;
 	if (ggblist->tagged && (iter = g_list_find(ggblist->tagged, node)) != NULL) {
@@ -1020,6 +1022,9 @@
 	GaimGroup *tg = NULL;
 	GaimContact *tc = NULL;
 
+	if (target == NULL)
+		return;
+
 	/* This target resolution probably needs more clarification; for
 	 * example, if I tag a buddy in a contact, then place on
 	 * another buddy in the same contact, I probably intend to