mirror of
https://github.com/pissnet/angiosperm.git
synced 2025-05-13 03:55:03 +01:00
Replace most checks for +o with oper:general
I'm preparing to PR a succession of privs changes with the ultimate goal of severely limiting the scope of the binary oper/user dichotomy and move conceptually distinct oper functions into their own privs. Accomplishing this is a non-trivial task, and can wait, but it's inconvenient now to have such functions enabled by the same mechanism that grants any privs at all--so I'm moving all of them to a transitional priv with the intention of eroding that later.
This commit is contained in:
parent
ad7ecd5cbb
commit
d4f7eb4ce6
34 changed files with 91 additions and 74 deletions
ircd
|
@ -1237,6 +1237,9 @@ user_mode(struct Client *client_p, struct Client *source_p, int parc, const char
|
|||
source_p->umodes &= ~UMODE_ADMIN;
|
||||
}
|
||||
|
||||
if(MyClient(source_p))
|
||||
source_p->handler = IsOperGeneral(source_p) ? OPER_HANDLER : CLIENT_HANDLER;
|
||||
|
||||
/* let modules providing usermodes know that we've changed our usermode --nenolod */
|
||||
hdata.client = source_p;
|
||||
hdata.oldumodes = setflags;
|
||||
|
@ -1439,6 +1442,8 @@ oper_up(struct Client *source_p, struct oper_conf *oper_p)
|
|||
hdata.oldsnomask = oldsnomask;
|
||||
call_hook(h_umode_changed, &hdata);
|
||||
|
||||
source_p->handler = IsOperGeneral(source_p) ? OPER_HANDLER : CLIENT_HANDLER;
|
||||
|
||||
sendto_realops_snomask(SNO_GENERAL, L_ALL,
|
||||
"%s (%s!%s@%s) is now an operator", oper_p->name, source_p->name,
|
||||
source_p->username, source_p->host);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue