X-Git-Url: https://jfr.im/git/irc/rqf/shadowircd.git/blobdiff_plain/212380e3f42f585dc1ea927402252eb943f91f7b..fc5ba333257059c155004618a542540b9a9ce721:/extensions/m_okick.c diff --git a/extensions/m_okick.c b/extensions/m_okick.c index 8fd7643..29e8b64 100644 --- a/extensions/m_okick.c +++ b/extensions/m_okick.c @@ -20,14 +20,13 @@ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 * USA * - * $Id: m_okick.c 3117 2007-01-02 13:11:04Z jilles $ + * $Id: m_okick.c 3554 2007-08-10 22:31:14Z jilles $ */ #include "stdinc.h" -#include "tools.h" #include "channel.h" #include "client.h" -#include "irc_string.h" +#include "match.h" #include "ircd.h" #include "numeric.h" #include "send.h" @@ -49,11 +48,10 @@ struct Message okick_msgtab = { mapi_clist_av1 okick_clist[] = { &okick_msgtab, NULL }; -DECLARE_MODULE_AV1(okick, NULL, NULL, okick_clist, NULL, NULL, "$Revision: 3117 $"); +DECLARE_MODULE_AV1(okick, NULL, NULL, okick_clist, NULL, NULL, "$Revision: 3554 $"); /* ** m_okick -** parv[0] = sender prefix ** parv[1] = channel ** parv[2] = client to kick ** parv[3] = kick comment @@ -74,7 +72,7 @@ mo_okick(struct Client *client_p, struct Client *source_p, int parc, const char if(*parv[2] == '\0') { - sendto_one(source_p, form_str(ERR_NEEDMOREPARAMS), me.name, parv[0], "KICK"); + sendto_one(source_p, form_str(ERR_NEEDMOREPARAMS), me.name, source_p->name, "KICK"); return 0; } @@ -109,14 +107,14 @@ mo_okick(struct Client *client_p, struct Client *source_p, int parc, const char if((target_p = find_client(user)) == NULL) { - sendto_one(source_p, form_str(ERR_NOSUCHNICK), me.name, parv[0], user); + sendto_one(source_p, form_str(ERR_NOSUCHNICK), me.name, source_p->name, user); return 0; } if((msptr = find_channel_membership(chptr, target_p)) == NULL) { sendto_one(source_p, form_str(ERR_USERNOTINCHANNEL), - me.name, parv[0], parv[1], parv[2]); + me.name, source_p->name, parv[1], parv[2]); return 0; } @@ -135,8 +133,8 @@ mo_okick(struct Client *client_p, struct Client *source_p, int parc, const char sendto_channel_local(ALL_MEMBERS, chptr, ":%s KICK %s %s :%s", me.name, chptr->chname, who->name, comment); - sendto_server(&me, chptr, NOCAPS, NOCAPS, - ":%s KICK %s %s :%s", me.name, chptr->chname, who->name, comment); + sendto_server(&me, chptr, CAP_TS6, NOCAPS, + ":%s KICK %s %s :%s", me.id, chptr->chname, who->id, comment); remove_user_from_channel(msptr); return 0; }