chmode: priv checks only for local clients

This commit is contained in:
Ed Kellett 2020-01-04 16:14:34 +00:00
parent b549e8e80d
commit 076973363a
No known key found for this signature in database
GPG key ID: CB9986DEF342FABC

View file

@ -660,7 +660,7 @@ chm_hidden(struct Client *source_p, struct Channel *chptr,
int alevel, int parc, int *parn,
const char **parv, int *errors, int dir, char c, long mode_type)
{
if(!IsOperGeneral(source_p) && !IsServer(source_p))
if(MyClient(source_p) && !IsOperGeneral(source_p))
{
if(!(*errors & SM_ERR_NOPRIVS))
sendto_one_numeric(source_p, ERR_NOPRIVILEGES, form_str(ERR_NOPRIVILEGES));
@ -707,7 +707,7 @@ chm_staff(struct Client *source_p, struct Channel *chptr,
int alevel, int parc, int *parn,
const char **parv, int *errors, int dir, char c, long mode_type)
{
if(!IsOper(source_p) && !IsServer(source_p))
if(MyClient(source_p) && !IsOper(source_p))
{
if(!(*errors & SM_ERR_NOPRIVS))
sendto_one_numeric(source_p, ERR_NOPRIVILEGES, form_str(ERR_NOPRIVILEGES));