summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authordanieldg <danieldg@e03df62e-2008-0410-955e-edbf42e46eb7>2009-09-13 20:31:03 +0000
committerdanieldg <danieldg@e03df62e-2008-0410-955e-edbf42e46eb7>2009-09-13 20:31:03 +0000
commitace3d85982f99ab04318ce705fd29fec5ffd7320 (patch)
tree9f6fee419ab1195b64470a6304277a3ec02c256d /src
parent91df762e93212958db487d8517addba1a63a4ddd (diff)
Remove double prefix conversion from Channel::RawWriteAllExcept
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@11698 e03df62e-2008-0410-955e-edbf42e46eb7
Diffstat (limited to 'src')
-rw-r--r--src/channels.cpp9
1 files changed, 8 insertions, 1 deletions
diff --git a/src/channels.cpp b/src/channels.cpp
index 0a4ef993d..2a0079bc1 100644
--- a/src/channels.cpp
+++ b/src/channels.cpp
@@ -691,12 +691,19 @@ void Channel::WriteAllExcept(User* user, bool serversource, char status, CUList
void Channel::RawWriteAllExcept(User* user, bool serversource, char status, CUList &except_list, const std::string &out)
{
+ char statmode = 0;
+ if (status)
+ {
+ ModeHandler* mh = ServerInstance->Modes->FindPrefix(status);
+ if (mh)
+ statmode = mh->GetModeChar();
+ }
for (UserMembIter i = userlist.begin(); i != userlist.end(); i++)
{
if ((IS_LOCAL(i->first)) && (except_list.find(i->first) == except_list.end()))
{
/* User doesnt have the status we're after */
- if (status && !strchr(this->GetAllPrefixChars(i->first), status))
+ if (statmode && !i->second->hasMode(statmode))
continue;
i->first->Write(out);