Add away-notify support

This commit is contained in:
TingPing
2013-03-12 02:21:18 -04:00
parent c76dedd9b9
commit bf0fb9f327
6 changed files with 39 additions and 2 deletions

View File

@@ -977,6 +977,25 @@ inbound_away (server *serv, char *nick, char *msg)
}
}
void
inbound_away_notify (server *serv, char *nick, char *reason)
{
session *sess = NULL;
GSList *list;
list = sess_list;
while (list)
{
sess = list->data;
if (sess->server == serv)
if (!reason)
userlist_set_away (sess, nick, FALSE);
else
userlist_set_away (sess, nick, TRUE);
list = list->next;
}
}
int
inbound_nameslist_end (server *serv, char *chan)
{