commit 03acae970df0ebe713a4be791e6c75915d34a365 from: Alexander Barton date: Sun Feb 25 02:22:05 2018 UTC User mode "C": Allow messages from servers, services, and IRC Ops Update user mode "C" handling ("Only users that share a channel are allowed to send messages") to behave like user mode "b" ("block private messages and notices") and therefore allow messages from servers, services, and IRC Operators, too. Change proposed by "wowaname" in #ngircd, thanks! commit - 8f0c705029501141528fbe7671e4107b4e1f395f commit + 03acae970df0ebe713a4be791e6c75915d34a365 blob - dc3b2f2ecf120a4147074cae869f5406d6c9fb98 blob + 12fd8214f4235165941b3606f99b112d08284f42 --- src/ngircd/irc.c +++ src/ngircd/irc.c @@ -694,7 +694,10 @@ Send_Message(CLIENT * Client, REQUEST * Req, int Force goto send_next_target; } - if (Client_HasMode(cl, 'C')) { + if (Client_HasMode(cl, 'C') && + !Client_HasMode(from, 'o') && + !(Client_Type(from) == CLIENT_SERVER) && + !(Client_Type(from) == CLIENT_SERVICE)) { cl2chan = Channel_FirstChannelOf(cl); while (cl2chan) { chan = Channel_GetChannel(cl2chan);