summaryrefslogtreecommitdiff
path: root/modules/core
diff options
context:
space:
mode:
authormichael <michael@82007160-df01-0410-b94d-b575c5fd34c7>2013-05-05 18:08:01 +0000
committermichael <michael@82007160-df01-0410-b94d-b575c5fd34c7>2013-05-05 18:08:01 +0000
commit03eb4fcaf75895859acfd1384d036f28b4f01c80 (patch)
treed5cbcb7303436278373b7899326ed0e7ec3dc1d4 /modules/core
parenta77bd0e21d1e479b48327cfbf13aaa2fec4522b4 (diff)
- Backport -r1895 [m_mode(): these buffers don't need to be static]
git-svn-id: svn://svn.ircd-hybrid.org/svnroot/ircd-hybrid/branches/8.1.x@1952 82007160-df01-0410-b94d-b575c5fd34c7
Diffstat (limited to 'modules/core')
-rw-r--r--modules/core/m_mode.c19
1 files changed, 8 insertions, 11 deletions
diff --git a/modules/core/m_mode.c b/modules/core/m_mode.c
index 897ce59..dbc777f 100644
--- a/modules/core/m_mode.c
+++ b/modules/core/m_mode.c
@@ -50,9 +50,9 @@ m_mode(struct Client *client_p, struct Client *source_p,
int parc, char *parv[])
{
struct Channel *chptr = NULL;
- struct Membership *member;
- static char modebuf[MODEBUFLEN];
- static char parabuf[MODEBUFLEN];
+ struct Membership *member = NULL;
+ char modebuf[MODEBUFLEN];
+ char parabuf[MODEBUFLEN];
if (EmptyString(parv[1]))
{
@@ -86,18 +86,17 @@ m_mode(struct Client *client_p, struct Client *source_p,
me.name, source_p->name, chptr->chname, modebuf, parabuf);
sendto_one(source_p, form_str(RPL_CREATIONTIME),
me.name, source_p->name, chptr->chname, chptr->channelts);
+ return;
}
- /* bounce all modes from people we deop on sjoin
+
+ /*
+ * bounce all modes from people we deop on sjoin
* servers have always gotten away with murder,
* including telnet servers *g* - Dianora
- *
- * XXX Is it worth the bother to make an ms_mode() ? - Dianora
*/
- else if (IsServer(source_p))
- {
+ if (IsServer(source_p))
set_channel_mode(client_p, source_p, chptr, NULL, parc - 2, parv + 2,
chptr->chname);
- }
else
{
member = find_channel_link(source_p, chptr);
@@ -106,10 +105,8 @@ m_mode(struct Client *client_p, struct Client *source_p,
{
/* Finish the flood grace period... */
if (MyClient(source_p) && !IsFloodDone(source_p))
- {
if (!((parc == 3) && (parv[2][0] == 'b') && (parv[2][1] == '\0')))
flood_endgrace(source_p);
- }
set_channel_mode(client_p, source_p, chptr, member, parc - 2, parv + 2,
chptr->chname);