[IRCServices Coding] A subtle levels bug
Andrew Church
achurch at achurch.org
Sun Feb 3 01:51:13 PST 2002
>I'm running Bahamut with IRCServices 5, and I've spotted a chanserv
>levels bug:
>
>Pertinent Channel level settings:
>AUTOVOICE 0
>AUTOHALFOP 4 (although it isn't used, because Bahamut doesn't support
>hop)
>
>A user with access level 4 enters the channel. He is not autovoiced,
>despite being above the AUTOVOICE leve, because he would be be hopped if
>this wasn't bahamut, so he is left with no modes.
>
>The bahamut protocol module needs to recognise this situation and voice
>him.
Protocol modules don't touch ChanServ, as they shouldn't. The CS
access code is supposed to take care of this automatically by deleting the
AUTOHALFOP and HALFOP levels (see access.c:init_access()) when the protocol
module signals that it doesn't have halfop capability, but it doesn't seem
to be working correctly. I'll look into it.
>I found this one by fidding about with my last bug, and is best summed
>up by this transcript (my comments in [square brackets]):
>
>-> ChanServ levels #chat list
><ChanServ> Access level settings for channel #chat:
><ChanServ> AUTOPROTECT 10
><ChanServ> AUTOOP 5
><ChanServ> AUTOHALFOP 4
><ChanServ> AUTOVOICE 0
[..]
>-> ChanServ levels #chat DIS AUTOHALFOP
><ChanServ> AUTOHALFOP disabled on channel #chat.
>
>-> ChanServ levels #chat list
><ChanServ> Access level settings for channel #chat:
><ChanServ> AUTOPROTECT 10
><ChanServ> AUTOOP 5
><ChanServ> AUTOHALFOP (disabled) [AUTOHALFOP is disabled... all good so far]
><ChanServ> AUTOVOICE 3 [hello... AUTOVOICE is randomly reset...]
><ChanServ> AUTODEOP -1
><ChanServ> NOJOIN -2
><ChanServ> INVITE 5
><ChanServ> AKICK 10
><ChanServ> SET 10000 [SET and CLEAR - formerly disabled, are now level 10000!]
><ChanServ> CLEAR 10000
Fixed (logic bug in LEVELS DISABLE), thanks for the report.
Incidentally, the "10000" should read "(founder only)", and that's already
fixed for the next release.
--Andrew Church
achurch at achurch.org
http://achurch.org/