summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorgeniusdex geniusdex@31f1291d-b8d6-0310-a050-a5561fc1590b <geniusdex geniusdex@31f1291d-b8d6-0310-a050-a5561fc1590b@5417fbe8-f217-4b02-8779-1006273d7864>2005-05-06 06:15:18 +0000
committergeniusdex geniusdex@31f1291d-b8d6-0310-a050-a5561fc1590b <geniusdex geniusdex@31f1291d-b8d6-0310-a050-a5561fc1590b@5417fbe8-f217-4b02-8779-1006273d7864>2005-05-06 06:15:18 +0000
commitdcb587f4ca47ba471e4f3f9ee2545fbeb82fa56f (patch)
tree5d0346204c1455639f7772cffd1ce7a8d359e4de
parent4b55c527516069dcae31cb06dba1c60b697eb465 (diff)
BUILD : 1.7.9 (781) BUGS : 358 364 NOTES : Changed chan_set_correct_modes() to allow identified founders to get founder is SECUREFOUNDER is on. Added code in delchan() to logout people identified as founder to the channel dropped.
git-svn-id: svn://svn.anope.org/anope/trunk@781 31f1291d-b8d6-0310-a050-a5561fc1590b git-svn-id: http://anope.svn.sourceforge.net/svnroot/anope/trunk@541 5417fbe8-f217-4b02-8779-1006273d7864
-rw-r--r--Changes2
-rw-r--r--src/channels.c11
-rw-r--r--src/chanserv.c30
-rw-r--r--version.log6
4 files changed, 39 insertions, 10 deletions
diff --git a/Changes b/Changes
index 55717387c..4ff57d926 100644
--- a/Changes
+++ b/Changes
@@ -1,5 +1,7 @@
Anope Version S V N
-------------------
+05/06 F Identified founders are now logged out if the channel is dropped. [#364]
+05/06 F Founders identified by pass can get founder chanmode again. [#358]
05/05 F Segfault in ns_maxemail when passing wrong param count. [ #00]
05/05 F ULined servers still got their modes removed with SecureOps on. [ #00]
05/05 F Missing access checks when removing modes due to SecureOps. [#366]
diff --git a/src/channels.c b/src/channels.c
index f0a1596a2..9b8efc715 100644
--- a/src/channels.c
+++ b/src/channels.c
@@ -1297,10 +1297,7 @@ void chan_set_correct_modes(User * user, Channel * c, int give_modes)
alog("debug: Setting correct user modes for %s on %s (current status: %d, %sgiving modes)", user->nick, c->name, status, (give_modes ? "" : "not "));
if (give_modes && (get_ignore(user->nick) == NULL)) {
- if (ircd->owner
- &&
- (((ci->flags & CI_SECUREFOUNDER) && is_real_founder(user, ci))
- || (!(ci->flags & CI_SECUREFOUNDER) && is_founder(user, ci))))
+ if (ircd->owner && is_founder(user, ci))
add_modes |= CUS_OWNER;
else if ((ircd->protect || ircd->admin)
&& check_access(user, ci, CA_AUTOPROTECT))
@@ -1320,11 +1317,7 @@ void chan_set_correct_modes(User * user, Channel * c, int give_modes)
*/
if (((ci->flags & CI_SECUREOPS) || (c->usercount == 1))
&& !is_ulined(user->server->name)) {
- if (ircd->owner && (status & CUS_OWNER)
- &&
- !(((ci->flags & CI_SECUREFOUNDER) && is_real_founder(user, ci))
- || (!(ci->flags & CI_SECUREFOUNDER)
- && is_founder(user, ci))))
+ if (ircd->owner && (status & CUS_OWNER) && !is_founder(user, ci))
rem_modes |= CUS_OWNER;
if ((ircd->protect || ircd->admin) && (status & CUS_PROTECT)
&& !check_access(user, ci, CA_AUTOPROTECT)
diff --git a/src/chanserv.c b/src/chanserv.c
index 52b22f8fd..70643e7d6 100644
--- a/src/chanserv.c
+++ b/src/chanserv.c
@@ -1933,6 +1933,8 @@ int delchan(ChannelInfo * ci)
{
int i;
NickCore *nc;
+ User *u;
+ struct u_chaninfolist *cilist, *cilist_next;
if (!ci) {
if (debug) {
@@ -1975,6 +1977,34 @@ int delchan(ChannelInfo * ci)
alog("debug: delchan() rdb done");
}
#endif
+ if (debug >= 2) {
+ alog("debug: delchan() founder cleanup");
+ }
+ for (i = 0; i < 1024; i++) {
+ for (u = userlist[i]; u; u = u->next) {
+ cilist = u->founder_chans;
+ while (cilist) {
+ cilist_next = cilist->next;
+ if (cilist->chan == ci) {
+ if (debug)
+ alog("debug: Dropping founder login of %s for %s",
+ u->nick, ci->name);
+ if (cilist->next)
+ cilist->next->prev = cilist->prev;
+ if (cilist->prev)
+ cilist->prev->next = cilist->next;
+ else
+ u->founder_chans = cilist->next;
+ free(cilist);
+ }
+ cilist = cilist_next;
+ }
+ }
+ }
+ if (debug >= 2) {
+ alog("debug: delchan() founder cleanup done");
+ }
+
if (ci->next)
ci->next->prev = ci->prev;
if (ci->prev)
diff --git a/version.log b/version.log
index c12e15256..f807dbce0 100644
--- a/version.log
+++ b/version.log
@@ -8,10 +8,14 @@
VERSION_MAJOR="1"
VERSION_MINOR="7"
VERSION_PATCH="9"
-VERSION_BUILD="780"
+VERSION_BUILD="781"
# $Log$
#
+# BUILD : 1.7.9 (781)
+# BUGS : 358 364
+# NOTES : Changed chan_set_correct_modes() to allow identified founders to get founder is SECUREFOUNDER is on. Added code in delchan() to logout people identified as founder to the channel dropped.
+#
# BUILD : 1.7.9 (780)
# BUGS : none
# NOTES : Language to clarify configuration directive dependencies.