From 6dadb437999760fc10757cf4b9faba4702b1c011 Mon Sep 17 00:00:00 2001 From: brain Date: Fri, 4 May 2007 16:23:40 +0000 Subject: Add which determines if auditorium works like ircnet +a (anonymous channels) or like unrealircd +u. The old behaviour is similar to anonymous channels, only showing the current user. git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@6875 e03df62e-2008-0410-955e-edbf42e46eb7 --- src/channels.cpp | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'src/channels.cpp') diff --git a/src/channels.cpp b/src/channels.cpp index 00f8dbce6..700487af9 100644 --- a/src/channels.cpp +++ b/src/channels.cpp @@ -802,7 +802,7 @@ char* chanrec::ChanModes(bool showkey) /* compile a userlist of a channel into a string, each nick seperated by * spaces and op, voice etc status shown as @ and +, and send it to 'user' */ -void chanrec::UserList(userrec *user) +void chanrec::UserList(userrec *user, CUList *ulist) { char list[MAXBUF]; size_t dlen, curlen; @@ -811,7 +811,7 @@ void chanrec::UserList(userrec *user) if (!IS_LOCAL(user)) return; - FOREACH_RESULT(I_OnUserList,OnUserList(user, this)); + FOREACH_RESULT(I_OnUserList,OnUserList(user, this, ulist)); if (MOD_RESULT == 1) return; @@ -820,7 +820,8 @@ void chanrec::UserList(userrec *user) int numusers = 0; char* ptr = list + dlen; - CUList *ulist= this->GetUsers(); + if (!ulist) + ulist= this->GetUsers(); /* Improvement by Brain - this doesnt change in value, so why was it inside * the loop? -- cgit v1.2.3