2 * IRC - Internet Relay Chat, ircd/m_zombie.c
3 * Copyright (C) 2011 Jan Krueger <jk@jk.gs>
5 * See file AUTHORS in IRC package for additional names of
8 * This program is free software; you can redistribute it and/or modify
9 * it under the terms of the GNU General Public License as published by
10 * the Free Software Foundation; either version 1, or (at your option)
13 * This program is distributed in the hope that it will be useful,
14 * but WITHOUT ANY WARRANTY; without even the implied warranty of
15 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16 * GNU General Public License for more details.
18 * You should have received a copy of the GNU General Public License
19 * along with this program; if not, write to the Free Software
20 * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
30 #include "ircd_reply.h"
31 #include "ircd_string.h"
42 /** Handle a ZOMBIE message from a server connection.
44 * \a parv has the following elements:
45 * \li \a parv[1] is the numnick of the client to act on
47 * See @ref m_functions for discussion of the arguments.
48 * @param[in] cptr Client that sent us the message.
49 * @param[in] sptr Original source of message.
50 * @param[in] parc Number of arguments.
51 * @param[in] parv Argument vector.
53 int ms_zombie(struct Client* cptr, struct Client* sptr, int parc,
59 return need_more_params(sptr, "ZOMBIE");
62 return protocol_violation(cptr, "ZOMBIE from non-server %s",
65 if (!(acptr = findNUser(parv[1])))
66 return 0; /* Ignore for a user that QUIT; probably crossed (however unlikely) */
68 if (!IsAccount(acptr))
69 return protocol_violation(cptr, "ZOMBIE for user without account (%s)",
72 zombie_client(cptr, sptr, acptr);