summaryrefslogtreecommitdiff
path: root/src/chanserv.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/chanserv.c')
-rw-r--r--src/chanserv.c18
1 files changed, 9 insertions, 9 deletions
diff --git a/src/chanserv.c b/src/chanserv.c
index 4df46d1ef..2c60ec004 100644
--- a/src/chanserv.c
+++ b/src/chanserv.c
@@ -29,7 +29,7 @@ static int def_levels[][2] = {
{ CA_NOJOIN, -2 },
{ CA_INVITE, 5 },
{ CA_AKICK, 10 },
- { CA_SET, ACCESS_FOUNDER },
+ { CA_SET, ACCESS_QOP },
{ CA_CLEAR, ACCESS_FOUNDER },
{ CA_UNBAN, 5 },
{ CA_OPDEOP, 5 },
@@ -51,17 +51,17 @@ static int def_levels[][2] = {
{ CA_HALFOPME, 4 },
{ CA_HALFOP, 5 },
{ CA_PROTECTME, 10 },
- { CA_PROTECT, ACCESS_FOUNDER },
+ { CA_PROTECT, ACCESS_QOP },
{ CA_KICKME, 5 },
{ CA_KICK, 5 },
{ CA_SIGNKICK, ACCESS_FOUNDER },
{ CA_BANME, 5 },
{ CA_BAN, 5 },
{ CA_TOPIC, ACCESS_FOUNDER },
- { CA_INFO, ACCESS_FOUNDER },
- { CA_AUTOOWNER, ACCESS_FOUNDER },
+ { CA_INFO, ACCESS_QOP },
+ { CA_AUTOOWNER, ACCESS_QOP },
{ CA_OWNER, ACCESS_FOUNDER },
- { CA_OWNERME, ACCESS_FOUNDER },
+ { CA_OWNERME, ACCESS_QOP },
{ -1 }
};
@@ -856,10 +856,10 @@ int check_access(User * user, ChannelInfo * ci, int what)
if (limit == ACCESS_INVALID)
return 0;
- if (what == ACCESS_FOUNDER)
- return IsFounder(user, ci);
- if (level >= ACCESS_FOUNDER)
- return (what == CA_AUTODEOP || what == CA_NOJOIN) ? 0 : 1;
+ if (limit > ACCESS_FOUNDER)
+ return 1;
+ if (limit == ACCESS_FOUNDER)
+ return (what == CA_AUTODEOP || what == CA_NOJOIN ? !IsRealFounder(user, ci) : IsRealFounder(user, ci));
/* Hacks to make flags work */
if (what == CA_AUTODEOP && (ci->HasFlag(CI_SECUREOPS)) && level == 0)
return 1;