1
0
mirror of https://github.com/anope/anope.git synced 2026-06-30 17:06:39 +02:00

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
This commit is contained in:
jantje_85
2009-11-25 22:57:00 +00:00
parent 822e75b501
commit 84ac00e953
4 changed files with 10 additions and 8 deletions
+2
View File
@@ -18,6 +18,8 @@ Provided by Anope Dev. <team@anope.org> - 2009
08/30 F Fixed MLOCK superseding DEFCON mode lock. [ #00]
09/09 F Fixed number of TS6 compatibility issues. [#1096]
10/06 F Fixed CS FORBID not clearing excepts & invites. [#1097]
11/25 F Fixed a number of major XOP related issues. [ #00]
11/25 F Fixed a bug in CLEAR OPS causing incorrect mode removal. [#1114]
Provided by Han` <Han@mefalcon.org> - 2009
07/28 F Updated german language file. [ #00]
+2 -2
View File
@@ -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;
+3 -5
View File
@@ -174,9 +174,10 @@ int do_vop(User * u)
int xop_del(User * u, ChannelInfo * ci, ChanAccess * access, int *perm, int uacc, int xlev)
{
char *nick;
if (!access->in_use || !access->nc || access->level != xlev)
return 0;
char *nick = access->nc->display;
nick = access->nc->display;
if (!is_services_admin(u) && uacc <= access->level) {
(*perm)++;
return 0;
@@ -339,7 +340,7 @@ int do_xop(User * u, char *xname, int xlev, int *xmsgs)
}
} else if (stricmp(cmd, "DEL") == 0) {
int deleted, a, b;
int deleted;
if (readonly) {
notice_lang(s_ChanServ, u, xmsgs[1]);
return MOD_CONT;
@@ -439,9 +440,6 @@ int do_xop(User * u, char *xname, int xlev, int *xmsgs)
if (!sent_header)
notice_lang(s_ChanServ, u, xmsgs[7], chan);
} else if (stricmp(cmd, "CLEAR") == 0) {
uint16 j = 0;
int a, b;
if (readonly) {
notice_lang(s_ChanServ, u, CHAN_ACCESS_DISABLED);
return MOD_CONT;
+3 -1
View File
@@ -9,9 +9,11 @@ VERSION_MAJOR="1"
VERSION_MINOR="8"
VERSION_PATCH="2"
VERSION_EXTRA="-svn"
VERSION_BUILD="2667"
VERSION_BUILD="2671"
# $Log$ # Changes since 1.8.2 Release
#Revision 2671 - 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.
#Revision 2668 - Fix a few more XOP related problems.
#Revision 2667 - Cleaned up a lot of the channel access reordering code, properly change users with less than voice access on channels to XOP, and fix a potential crashbug after switching to XOP on IRCds that do not support halfop
#Revision 2601 - All usermodes are now recognized and properly set internally on Insp 1.2.
#Revision 2598 - More dynamic detection of channel modes on InspIRCd 1.2. Also fixes params being linked to the wrong mode.