diff options
author | brain <brain@e03df62e-2008-0410-955e-edbf42e46eb7> | 2006-01-22 19:33:53 +0000 |
---|---|---|
committer | brain <brain@e03df62e-2008-0410-955e-edbf42e46eb7> | 2006-01-22 19:33:53 +0000 |
commit | 715dab175374ee11609f013b103c1b0f579192bc (patch) | |
tree | 95ac4bb24a6102899804486ba92e9ae8b6be3781 | |
parent | 93e3cda102be0870171ecd9ad0d6507566c7ffd1 (diff) |
Fixes to make server kicks work
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@2831 e03df62e-2008-0410-955e-edbf42e46eb7
-rw-r--r-- | src/channels.cpp | 4 | ||||
-rw-r--r-- | src/modules.cpp | 6 |
2 files changed, 5 insertions, 5 deletions
diff --git a/src/channels.cpp b/src/channels.cpp index 9179c8002..4a110bdb2 100644 --- a/src/channels.cpp +++ b/src/channels.cpp @@ -474,7 +474,7 @@ void server_kick_channel(userrec* user, chanrec* Ptr, char* reason, bool trigger if (user->chans[i].channel) if (!strcasecmp(user->chans[i].channel->name,Ptr->name)) { - WriteChannelWithServ(Ptr,"KICK %s %s :%s",Ptr->name, user->nick, reason); + WriteChannelWithServ(Config->ServerName,Ptr,"KICK %s %s :%s",Ptr->name, user->nick, reason); user->chans[i].uc_modes = 0; user->chans[i].channel = NULL; break; @@ -491,7 +491,7 @@ void server_kick_channel(userrec* user, chanrec* Ptr, char* reason, bool trigger if (iter != chanlist.end()) { log(DEBUG,"del_channel: destroyed: %s",Ptr->name); - FOREACH_MOD(I_OnChannelDelete,OnChannelDelete(Ptr)); + FOREACH_MOD(I_OnChannelDelete,OnChannelDelete(Ptr)); delete Ptr; chanlist.erase(iter); } diff --git a/src/modules.cpp b/src/modules.cpp index 5ac49e75a..2cfb586ca 100644 --- a/src/modules.cpp +++ b/src/modules.cpp @@ -408,15 +408,15 @@ void Server::ChangeUserNick(userrec* user, std::string nickname) force_nickchange(user,nickname.c_str()); } -virtual void KickUser(userrec* source, userrec* target, chanrec* chan, std::string reason) +void Server::KickUser(userrec* source, userrec* target, chanrec* chan, std::string reason) { if (source) { - kick_channel(source,target,chan,reason); + kick_channel(source,target,chan,(char*)reason.c_str()); } else { - server_kick_channel(target,chan,reason,true); + server_kick_channel(target,chan,(char*)reason.c_str(),true); } } |