Commit d3fd88a406cae91cbbbdad1c0112075d004fee53 introduced sendto_channel_local_priv() as a useful refactoring of the ONLY_OPERS hack in sendto_channel_local().
This works by introducing a new priv argument, which points to a string containing either the required privileges or NULL.
The same change, however, sends an empty string as the priv argument for unprivileged modes, causing modes to not be distributed. So we change that priv argument to NULL.
Otherwise, sendto_channel_local_priv() will only distribute mode changes to opers only. This is because HasPrivilege(target_p, "") will evaluate as false due to the target not being opered.
Commit d3fd88a406cae91cbbbdad1c0112075d004fee53 introduced
sendto_channel_local_priv()
as a useful refactoring of theONLY_OPERS
hack insendto_channel_local()
.This works by introducing a new
priv
argument, which points to a string containing either the required privileges orNULL
.The same change, however, sends an empty string as the
priv
argument for unprivileged modes, causing modes to not be distributed. So we change thatpriv
argument toNULL
.Otherwise,
sendto_channel_local_priv()
will only distribute mode changes to opers only. This is becauseHasPrivilege(target_p, "")
will evaluate as false due to the target not being opered.Thanks to Devin Brown for bisecting this issue.