From 2d0e736f335391b21b63461953c397b889daf7ec Mon Sep 17 00:00:00 2001 From: Daniel De Graaf Date: Tue, 28 Sep 2010 11:01:45 -0400 Subject: Fix kicking permisisons - GetPrefixChar returns the prefix, not the mode character --- src/channels.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/channels.cpp b/src/channels.cpp index 01450ce61..5779fb50b 100644 --- a/src/channels.cpp +++ b/src/channels.cpp @@ -523,10 +523,10 @@ void Channel::KickUser(User *src, User *user, const char* reason) if (res == MOD_RES_DENY) return; - if (res == MOD_RES_PASSTHRU) + if (res == MOD_RES_PASSTHRU && !memb->modes.empty()) { int them = this->GetPrefixValue(src); - char us = GetPrefixChar(user)[0]; + char us = memb->modes[0]; ModeHandler* mh = ServerInstance->Modes->FindMode(us, MODETYPE_CHANNEL); int min = mh ? mh->GetLevelRequired() : HALFOP_VALUE; if (them < HALFOP_VALUE || them < min) -- cgit v1.2.3