From 9a9279d9759e995d9aae78065c3eb8805589c255 Mon Sep 17 00:00:00 2001 From: Michael Poole Date: Tue, 18 Nov 2008 03:18:46 +0000 Subject: [PATCH] Properly handle net rider kicks that are received after a normal kick for the same user. git-svn-id: file:///home/klmitch/undernet-ircu/undernet-ircu-svn/ircu2/branches/u2_10_12_branch@1893 c9e4aea6-c8fd-4c43-8297-357d70d61c8c --- ChangeLog | 5 +++++ ircd/m_kick.c | 15 ++++++++++++++- 2 files changed, 19 insertions(+), 1 deletion(-) diff --git a/ChangeLog b/ChangeLog index e96b988..378f262 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2008-11-17 Michael Poole + + * ircd/m_kick.c (ms_kick): Properly handle crossing net rider and + normal KICKs (in the case where we get the normal kick first). + 2008-11-17 Michael Poole * ircd/match.c (match): Fix an error in backtracking (apparently diff --git a/ircd/m_kick.c b/ircd/m_kick.c index 2c95a8e..c789e37 100644 --- a/ircd/m_kick.c +++ b/ircd/m_kick.c @@ -206,8 +206,21 @@ int ms_kick(struct Client *cptr, struct Client *sptr, int parc, char *parv[]) return 0; /* We go ahead and pass on the KICK for users not on the channel */ - if (!(member = find_member_link(chptr, who)) || IsZombie(member)) + member = find_member_link(chptr, who); + if (member && IsZombie(member)) + { + /* We might get a KICK from a zombie's own server because the user + * net-rode during a burst (which always generates a KICK) *and* + * was kicked via another server. In that case, we must remove + * the user from the channel. + */ + if (sptr == cli_user(who)->server) + { + remove_user_from_channel(who, chptr); + } + /* Otherwise, we treat zombies like they are not channel members. */ member = 0; + } /* Send HACK notice, but not for servers in BURST */ /* 2002-10-17: Don't send HACK if the users local server is kicking them */ -- 2.20.1