diff options
author | jantje_85 <jantje_85@5417fbe8-f217-4b02-8779-1006273d7864> | 2009-11-25 22:57:00 +0000 |
---|---|---|
committer | jantje_85 <jantje_85@5417fbe8-f217-4b02-8779-1006273d7864> | 2009-11-25 22:57:00 +0000 |
commit | 84ac00e953c9d8a03bd7b76bcdf5de26832edcfa (patch) | |
tree | 264a08d96b6d4c8b0155211bd3a5e6efe1ac1645 /src/core/cs_clear.c | |
parent | 822e75b501efc57c533e65f68c55debd453415fd (diff) |
Fix bug #1114. Fixed a bug in cs_clear caused by do_cmode() modifying params passed to it.
Also fixed some warnings in cs_xop.
git-svn-id: http://anope.svn.sourceforge.net/svnroot/anope/stable@2671 5417fbe8-f217-4b02-8779-1006273d7864
Diffstat (limited to 'src/core/cs_clear.c')
-rw-r--r-- | src/core/cs_clear.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/core/cs_clear.c b/src/core/cs_clear.c index c3934d840..0b55a965d 100644 --- a/src/core/cs_clear.c +++ b/src/core/cs_clear.c @@ -186,7 +186,6 @@ int do_clear(User * u) struct c_userlist *cu, *next; if (ircd->svsmode_ucmode) { - av[0] = chan; anope_cmd_svsmode_chan(av[0], "-o", NULL); if (ircd->owner) { anope_cmd_svsmode_chan(av[0], ircd->ownerunset, NULL); @@ -207,6 +206,7 @@ int do_clear(User * u) snprintf(tmp, BUFSIZE, "-%s%s%s", (isop ? "o" : ""), (isadmin ? ircd->adminunset+1 : ""), (isown ? ircd->ownerunset+1 : "")); + av[0] = chan; if (ircdcap->tsmode) { snprintf(buf, BUFSIZE - 1, "%ld", (long int) time(NULL)); av[1] = buf; @@ -226,7 +226,6 @@ int do_clear(User * u) do_cmode(s_ChanServ, ac, av); } } else { - av[0] = chan; for (cu = c->users; cu; cu = next) { next = cu->next; isop = chan_has_user_status(c, cu->user, CUS_OP); @@ -243,6 +242,7 @@ int do_clear(User * u) snprintf(tmp2, BUFSIZE, "%s %s %s", (isop ? GET_USER(cu->user) : ""), (isadmin ? GET_USER(cu->user) : ""), (isown ? GET_USER(cu->user) : "")); + av[0] = chan; if (ircdcap->tsmode) { snprintf(buf, BUFSIZE - 1, "%ld", (long int) time(NULL)); av[1] = buf; |