diff src/prpl.c @ 4349:0c68d402f59f

[gaim-migrate @ 4614] XML Blist Gaim stores all the buddy lists in one big happy file now. You can order the buddies however you want, and they'll stay ordered that way. We can also store some per-buddy information now, which will be cool. committer: Tailor Script <tailor@pidgin.im>
author Nathan Walp <nwalp@pidgin.im>
date Sun, 19 Jan 2003 22:16:52 +0000
parents cc2f780c0505
children 5fb47ec9bfe4
line wrap: on
line diff
--- a/src/prpl.c	Sun Jan 19 22:03:57 2003 +0000
+++ b/src/prpl.c	Sun Jan 19 22:16:52 2003 +0000
@@ -646,11 +646,13 @@
 {
 	char buf[BUF_LONG];
 	struct got_add *ga = g_new0(struct got_add, 1);
+	struct buddy *b = find_buddy(gc->user, who);
 
 	ga->gc = gc;
 	ga->who = g_strdup(who);
 	ga->alias = alias ? g_strdup(alias) : NULL;
 
+
 	g_snprintf(buf, sizeof(buf), _("%s%s%s%s has made %s his or her buddy%s%s%s"),
 		   who,
 		   alias ? " (" : "",
@@ -659,8 +661,8 @@
 		   id ? id : gc->displayname[0] ? gc->displayname : gc->username,
 		   msg ? ": " : ".",
 		   msg ? msg : "",
-		   find_buddy(gc, ga->who) ? "" : _("\n\nDo you wish to add him or her to your buddy list?"));
-	if (find_buddy(gc, ga->who))
+		   b ? "" : _("\n\nDo you wish to add him or her to your buddy list?"));
+	if (b)
 		do_error_dialog(_("Gaim - Information"), buf, GAIM_INFO);
 	else
 		do_ask_dialog(_("Gaim - Confirm"), buf, ga, _("Add"), do_add, _("Cancel"), dont_add, NULL, FALSE);