]> jfr.im git - irc/freenode/solanum.git/commit
chmode: end the grace period more intelligently (#84)
authorEd Kellett <redacted>
Mon, 30 Nov 2020 09:24:32 +0000 (09:24 +0000)
committerGitHub <redacted>
Mon, 30 Nov 2020 09:24:32 +0000 (09:24 +0000)
commitb860ad5ffac21b14e916555b53cde304df08c304
tree8c26bcd457d3cf12ed5f146fce9f9a171af8a8b2
parent6638c837cce068adbc3d3dfdef136a30443f6724
chmode: end the grace period more intelligently (#84)

We were ending the flood grace period for any channel mode command other
than `MODE #foo [bq]` by means of a hardcoded check. I've moved that to
after we parse the mode string, so we can correctly identify all
requests to change modes and end the grace period on exactly those.

It would have been entirely possible to move the check even further down
and flood_endgrace on only mode commands that *actually* change modes,
but I don't like the idea of making it sensitive to external conditions.
ircd/chmode.c
modules/core/m_mode.c