ViewVC Help
View File | Revision Log | Show Annotations | View Changeset | Root Listing
root/svn/ircd-hybrid/branches/8.1.x/modules/m_ison.c
(Generate patch)

Comparing ircd-hybrid-8/modules/m_ison.c (file contents):
Revision 1156 by michael, Tue Aug 9 20:29:20 2011 UTC vs.
Revision 1230 by michael, Thu Sep 22 19:41:19 2011 UTC

# Line 35 | Line 35
35   #include "modules.h"
36   #include "s_conf.h" /* ConfigFileEntry */
37  
38 static void do_ison(struct Client *, struct Client *, int, char *[]);
39 static void m_ison(struct Client *, struct Client *, int, char *[]);
40
41 struct Message ison_msgtab = {
42  "ISON", 0, 0, 1, 1, MFLG_SLOW, 0,
43  {m_unregistered, m_ison, m_ignore, m_ignore, m_ison, m_ignore}
44 };
45
46 void
47 _modinit(void)
48 {
49  mod_add_cmd(&ison_msgtab);
50 }
51
52 void
53 _moddeinit(void)
54 {
55  mod_del_cmd(&ison_msgtab);
56 }
57
58 const char *_version = "$Revision$";
59
60
61 /*
62 * m_ison added by Darren Reed 13/8/91 to act as an efficent user indicator
63 * with respect to cpu/bandwidth used. Implemented for NOTIFY feature in
64 * clients. Designed to reduce number of whois requests. Can process
65 * nicknames in batches as long as the maximum buffer length.
66 *
67 * format:
68 * ISON :nicklist
69 */
70 static void
71 m_ison(struct Client *client_p, struct Client *source_p,
72       int parc, char *parv[])
73 {
74  do_ison(client_p, source_p, parc, parv);
75 }
38  
39   static void
40   do_ison(struct Client *client_p, struct Client *source_p,
# Line 87 | Line 49 | do_ison(struct Client *client_p, struct
49    int i;
50    int done = 0;
51  
52 <  len = ircsprintf(buf, form_str(RPL_ISON), me.name, parv[0]);
52 >  len = ircsprintf(buf, form_str(RPL_ISON), me.name, source_p->name);
53    current_insert_point = buf + len;
54  
55    /*
# Line 130 | Line 92 | do_ison(struct Client *client_p, struct
92  
93    sendto_one(source_p, "%s", buf);
94   }
95 +
96 + /*
97 + * m_ison added by Darren Reed 13/8/91 to act as an efficent user indicator
98 + * with respect to cpu/bandwidth used. Implemented for NOTIFY feature in
99 + * clients. Designed to reduce number of whois requests. Can process
100 + * nicknames in batches as long as the maximum buffer length.
101 + *
102 + * format:
103 + * ISON :nicklist
104 + */
105 + static void
106 + m_ison(struct Client *client_p, struct Client *source_p,
107 +       int parc, char *parv[])
108 + {
109 +  do_ison(client_p, source_p, parc, parv);
110 + }
111 +
112 + static struct Message ison_msgtab = {
113 +  "ISON", 0, 0, 1, 1, MFLG_SLOW, 0,
114 +  {m_unregistered, m_ison, m_ignore, m_ignore, m_ison, m_ignore}
115 + };
116 +
117 + static void
118 + module_init(void)
119 + {
120 +  mod_add_cmd(&ison_msgtab);
121 + }
122 +
123 + static void
124 + module_exit(void)
125 + {
126 +  mod_del_cmd(&ison_msgtab);
127 + }
128 +
129 + struct module module_entry = {
130 +  .node    = { NULL, NULL, NULL },
131 +  .name    = NULL,
132 +  .version = "$Revision$",
133 +  .handle  = NULL,
134 +  .modinit = module_init,
135 +  .modexit = module_exit,
136 +  .flags   = 0
137 + };

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines