]> arthur.barton.de Git - ngircd-alex.git/blobdiff - src/ngircd/irc-channel.c
Make the maximum /list reply length a configurable limit.
[ngircd-alex.git] / src / ngircd / irc-channel.c
index f9d2dc125d3708b11ad629ed9551b7f08f4b2598..ed4839afdcef63782be0510b876915d3522c8e10 100644 (file)
@@ -679,9 +679,10 @@ IRC_LIST( CLIENT *Client, REQUEST *Req )
                                if (!strchr(Channel_Modes(chan), 's')
                                    || Channel_IsMemberOf(chan, from)
                                    || (!Conf_MorePrivacy && Client_OperByMe(Client))) {
-                                       if (IRC_CheckListTooBig(from, count,
-                                                                MAX_RPL_LIST,
-                                                                "LIST"))
+                                       if ((Conf_MaxListSize > 0)
+                                           && IRC_CheckListTooBig(from, count,
+                                                                  Conf_MaxListSize,
+                                                                  "LIST"))
                                                break;
                                        if (!IRC_WriteStrClient(from,
                                             RPL_LIST_MSG, Client_ID(from),