don't subject remote users to chm_nonotice

amdj/dline-tls-code
Jess Porter 1 year ago committed by GitHub
parent 5a1b54fddc
commit 042218080e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -52,8 +52,11 @@ chm_nonotice_process(void *data_)
{
hook_data_privmsg_channel *data = data_;
/* don't waste CPU if message is already blocked */
if (data->approved || data->msgtype != MESSAGE_TYPE_NOTICE)
/*
* don't waste CPU if message is already blocked, only block notices,
* only check messages sourced from local clients (so we don't block services notices)
*/
if (data->approved || data->msgtype != MESSAGE_TYPE_NOTICE || !MyClient(data->source_p))
return;
/* block all notices except CTCPs; use chm_noctcp to block CTCPs. */

Loading…
Cancel
Save