changeset 4356:6d277ffb6daa

[gaim-migrate @ 4622] Gaim has improved A LOT since 0.59. "The first step in a successful revolution is destroying all competing revolutionaries." committer: Tailor Script <tailor@pidgin.im>
author Mark Doliner <mark@kingant.net>
date Mon, 20 Jan 2003 05:32:50 +0000
parents 33e5c088346b
children 367fc70fe4f7
files src/protocols/oscar/oscar.c
diffstat 1 files changed, 9 insertions(+), 5 deletions(-) [+]
line wrap: on
line diff
--- a/src/protocols/oscar/oscar.c	Mon Jan 20 05:09:00 2003 +0000
+++ b/src/protocols/oscar/oscar.c	Mon Jan 20 05:32:50 2003 +0000
@@ -5071,11 +5071,15 @@
 		pbm->gc = gc;
 		m = g_list_append(m, pbm);
 	} else {
-		pbm = g_new0(struct proto_buddy_menu, 1);
-		pbm->label = _("Get Away Msg");
-		pbm->callback = oscar_get_away_msg;
-		pbm->gc = gc;
-		m = g_list_append(m, pbm);
+		struct buddy *b = find_buddy(gc->user, who);
+
+		if (!b || (b->uc & UC_UNAVAILABLE)) {
+			pbm = g_new0(struct proto_buddy_menu, 1);
+			pbm->label = _("Get Away Msg");
+			pbm->callback = oscar_get_away_msg;
+			pbm->gc = gc;
+			m = g_list_append(m, pbm);
+		}
 
 		if (aim_sncmp(gc->username, who)) {
 			pbm = g_new0(struct proto_buddy_menu, 1);