1 |
|
/* |
2 |
< |
* ircd-hybrid: an advanced Internet Relay Chat Daemon(ircd). |
3 |
< |
* m_close.c: Closes all unregistered connections. |
2 |
> |
* ircd-hybrid: an advanced, lightweight Internet Relay Chat Daemon (ircd) |
3 |
|
* |
4 |
< |
* Copyright (C) 2002 by the past and present ircd coders, and others. |
4 |
> |
* Copyright (c) 1997-2014 ircd-hybrid development team |
5 |
|
* |
6 |
|
* This program is free software; you can redistribute it and/or modify |
7 |
|
* it under the terms of the GNU General Public License as published by |
17 |
|
* along with this program; if not, write to the Free Software |
18 |
|
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 |
19 |
|
* USA |
20 |
< |
* |
21 |
< |
* $Id$ |
20 |
> |
*/ |
21 |
> |
|
22 |
> |
/*! \file m_close.c |
23 |
> |
* \brief Includes required functions for processing the CLOSE command. |
24 |
> |
* \version $Id$ |
25 |
|
*/ |
26 |
|
|
27 |
|
#include "stdinc.h" |
38 |
|
* mo_close - CLOSE message handler |
39 |
|
* - added by Darren Reed Jul 13 1992. |
40 |
|
*/ |
41 |
< |
static void |
41 |
> |
static int |
42 |
|
mo_close(struct Client *client_p, struct Client *source_p, |
43 |
|
int parc, char *parv[]) |
44 |
|
{ |
54 |
|
get_client_name(target_p, SHOW_IP), target_p->status); |
55 |
|
|
56 |
|
/* |
57 |
< |
* exit here is safe, because it is guaranteed not to be source_p |
57 |
> |
* Exit here is safe, because it is guaranteed not to be source_p |
58 |
|
* because it is unregistered and source_p is an oper. |
59 |
|
*/ |
60 |
|
exit_client(target_p, target_p, "Oper Closing"); |
62 |
|
|
63 |
|
sendto_one(source_p, form_str(RPL_CLOSEEND), |
64 |
|
me.name, source_p->name, closed); |
65 |
+ |
return 0; |
66 |
|
} |
67 |
|
|
68 |
< |
static struct Message close_msgtab = { |
68 |
> |
static struct Message close_msgtab = |
69 |
> |
{ |
70 |
|
"CLOSE", 0, 0, 0, MAXPARA, MFLG_SLOW, 0, |
71 |
|
{ m_unregistered, m_not_oper, m_ignore, m_ignore, mo_close, m_ignore } |
72 |
|
}; |
83 |
|
mod_del_cmd(&close_msgtab); |
84 |
|
} |
85 |
|
|
86 |
< |
struct module module_entry = { |
86 |
> |
struct module module_entry = |
87 |
> |
{ |
88 |
|
.node = { NULL, NULL, NULL }, |
89 |
|
.name = NULL, |
90 |
|
.version = "$Revision$", |