From 559d53011113cd15ccfffbb087ea09e5c72cf56c Mon Sep 17 00:00:00 2001 From: "B.Greenham" Date: Fri, 5 Mar 2010 13:59:35 -0500 Subject: [PATCH] Make m_okick support the new +J format. --- NEWS | 2 +- extensions/m_okick.c | 5 +---- 2 files changed, 2 insertions(+), 5 deletions(-) diff --git a/NEWS b/NEWS index 77b8c47..8ff8239 100644 --- a/NEWS +++ b/NEWS @@ -16,7 +16,7 @@ new modes - Add cmode +N which disallows users from changing their nick while they're on a channel with this mode set. - Add cmode +K (norepeat) which will block repeated messages, regardless of -- who they're from. + who they're from. - Add cmode +G which blocks messages containing 50% or more capital letters from being sent to the channel. - Add cmode +J which disallows a kicked user from rejoining within 'X' seconds diff --git a/extensions/m_okick.c b/extensions/m_okick.c index 9da3a24..16ddcdd 100644 --- a/extensions/m_okick.c +++ b/extensions/m_okick.c @@ -69,7 +69,6 @@ mo_okick(struct Client *client_p, struct Client *source_p, int parc, const char char *p = NULL; char *user; static char buf[BUFSIZE]; - char *text = rb_strdup(""); if(*parv[2] == '\0') { @@ -138,10 +137,8 @@ mo_okick(struct Client *client_p, struct Client *source_p, int parc, const char ":%s KICK %s %s :%s", me.id, chptr->chname, who->id, comment); remove_user_from_channel(msptr); - rb_sprintf(text, "K%s", target_p->name); - /* we don't need to track NOREJOIN stuff unless it's our client being kicked */ if(MyClient(target_p) && chptr->mode.mode & MODE_NOREJOIN) - channel_metadata_time_add(chptr, text, rb_current_time()); + channel_metadata_time_add(chptr, "KICKNOREJOIN", rb_current_time(), target_p->id); return 0; }