Remove cruft left behind by removed stats_p_hook.
[seven-1.x.git] / modules / m_extendchans.c
blobde0d1143951b7c12bbb35aaa0bb56416bc211e01
1 /*
2 * ircd-seven: A slightly useful ircd.
3 * m_extendchans.c: Allow an oper or service to let a given user join more channels.
5 * Copyright (C) 1990 Jarkko Oikarinen and University of Oulu, Co Center
6 * Copyright (C) 1996-2002 Hybrid Development Team
7 * Copyright (C) 2002-2006 ircd-ratbox development team
8 * Copyright (C) 2006 ircd-seven development team
10 * This program is free software; you can redistribute it and/or modify
11 * it under the terms of the GNU General Public License as published by
12 * the Free Software Foundation; either version 2 of the License, or
13 * (at your option) any later version.
15 * This program is distributed in the hope that it will be useful,
16 * but WITHOUT ANY WARRANTY; without even the implied warranty of
17 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
18 * GNU General Public License for more details.
20 * You should have received a copy of the GNU General Public License
21 * along with this program; if not, write to the Free Software
22 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
23 * USA
26 #include "stdinc.h"
27 #include "client.h"
28 #include "modules.h"
29 #include "send.h"
30 #include "numeric.h"
32 static int me_extendchans(struct Client *, struct Client *, int, const char **);
34 struct Message extendchans_msgtab = {
35 "EXTENDCHANS", 0, 0, 0, MFLG_SLOW,
36 { mg_unreg, mg_not_oper, mg_ignore, mg_ignore, {me_extendchans, 1}, mg_ignore}
39 mapi_clist_av1 extendchans_clist[] = { &extendchans_msgtab, NULL };
41 DECLARE_MODULE_AV1(extendchans, NULL, NULL, extendchans_clist, NULL, NULL, "$Revision: $");
43 static int
44 me_extendchans(struct Client *client_p, struct Client *source_p, int parc, const char *parv[])
46 struct Client *target_p;
48 target_p = find_named_person(parv[1]);
49 if(target_p == NULL)
51 sendto_one_numeric(source_p, ERR_NOSUCHNICK, form_str(ERR_NOSUCHNICK), parv[1]);
52 return 0;
55 if(!MyClient(target_p))
56 return 0;
58 SetExemptChLimit(target_p);
60 return 0;