X-Git-Url: https://git.netwichtig.de/gitweb/?a=blobdiff_plain;f=src%2Fmodules%2Fm_banredirect.cpp;h=4a4188757c23f31c5f59c59c065214ba88de984d;hb=9c4cc196c073145d4ad2ae92fb2be2194cf621f4;hp=5202051f326cc1fd3d4f9857b9aec87b2986e29d;hpb=ee7ac5aaede95eb82ecc948d0e52ad01ddeaa6c9;p=user%2Fhenk%2Fcode%2Finspircd.git diff --git a/src/modules/m_banredirect.cpp b/src/modules/m_banredirect.cpp index 5202051f3..4a4188757 100644 --- a/src/modules/m_banredirect.cpp +++ b/src/modules/m_banredirect.cpp @@ -54,7 +54,7 @@ class BanRedirect : public ModeWatcher { } - bool BeforeMode(User* source, User* dest, Channel* channel, std::string ¶m, bool adding) + bool BeforeMode(User* source, User* dest, Channel* channel, std::string& param, bool adding) CXX11_OVERRIDE { /* nick!ident@host -> nick!ident@host * nick!ident@host#chan -> nick!ident@host#chan @@ -308,7 +308,7 @@ class ModuleBanRedirect : public Module if (destchan) destlimit = destchan->GetModeParameter(limitmode); - if(destchan && destchan->IsModeSet(redirectmode) && !destlimit.empty() && (destchan->GetUserCounter() >= atoi(destlimit.c_str()))) + if(destchan && destchan->IsModeSet(redirectmode) && !destlimit.empty() && (destchan->GetUserCounter() >= ConvToNum(destlimit))) { user->WriteNumeric(ERR_BANNEDFROMCHAN, chan->name, "Cannot join channel (You are banned)"); return MOD_RES_DENY;