mirror of
https://github.com/matrix-construct/construct
synced 2024-11-30 02:32:43 +01:00
Fix some tracking for cmode +r.
This commit is contained in:
parent
84c9a8c7be
commit
d463189921
1 changed files with 5 additions and 5 deletions
10
src/chmode.c
10
src/chmode.c
|
@ -1241,17 +1241,17 @@ chm_regonly(struct Client *source_p, struct Channel *chptr,
|
|||
if(dir == MODE_QUERY)
|
||||
return;
|
||||
|
||||
if(((dir == MODE_ADD) && (chptr->mode.mode & MODE_REGONLY)) ||
|
||||
((dir == MODE_DEL) && !(chptr->mode.mode & MODE_REGONLY)))
|
||||
if(((dir == MODE_ADD) && (chptr->mode.mode & mode_type)) ||
|
||||
((dir == MODE_DEL) && !(chptr->mode.mode & mode_type)))
|
||||
return;
|
||||
|
||||
if(MyClient(source_p) && (++mode_limit_simple > MAXMODES_SIMPLE))
|
||||
return;
|
||||
|
||||
if(dir == MODE_ADD)
|
||||
chptr->mode.mode |= MODE_REGONLY;
|
||||
chptr->mode.mode |= mode_type;
|
||||
else
|
||||
chptr->mode.mode &= ~MODE_REGONLY;
|
||||
chptr->mode.mode &= ~mode_type;
|
||||
|
||||
mode_changes[mode_count].letter = c;
|
||||
mode_changes[mode_count].dir = dir;
|
||||
|
@ -1380,7 +1380,7 @@ struct ChannelMode chmode_table[256] =
|
|||
{chm_op, 0 }, /* o */
|
||||
{chm_simple, MODE_PRIVATE }, /* p */
|
||||
{chm_ban, CHFL_QUIET }, /* q */
|
||||
{chm_regonly, 0 }, /* r */
|
||||
{chm_regonly, MODE_REGONLY }, /* r */
|
||||
{chm_simple, MODE_SECRET }, /* s */
|
||||
{chm_simple, MODE_TOPICLIMIT }, /* t */
|
||||
{chm_nosuch, 0 }, /* u */
|
||||
|
|
Loading…
Reference in a new issue