summary refs log tree commit diff stats
path: root/src/common/inbound.c
diff options
context:
space:
mode:
authorTingPing <tngpng@gmail.com>2013-04-03 12:12:26 -0700
committerTingPing <tngpng@gmail.com>2013-04-03 12:12:26 -0700
commit4c217d4ba35808f84099f705524399e703d09df7 (patch)
treedb64393741f8f1083c5d901470f96f2e3259be4a /src/common/inbound.c
parent23b20813853fba432687025c61733ee58b82e26c (diff)
parenteb5313f8503091017ecb81ad8d48be576a666a81 (diff)
Merge pull request #448 from TingPing/awaynotify2
Add away-notify support
Diffstat (limited to 'src/common/inbound.c')
-rw-r--r--src/common/inbound.c16
1 files changed, 16 insertions, 0 deletions
diff --git a/src/common/inbound.c b/src/common/inbound.c
index dae919b8..878a8759 100644
--- a/src/common/inbound.c
+++ b/src/common/inbound.c
@@ -986,6 +986,22 @@ 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)
+			userlist_set_away (sess, nick, reason ? TRUE : FALSE);
+		list = list->next;
+	}
+}
+
 int
 inbound_nameslist_end (server *serv, char *chan)
 {