]> jfr.im git - solanum.git/commitdiff
Fix weirdness with client_flood_burst_rate and client_flood_burst_max.
authorJilles Tjoelker <redacted>
Mon, 3 Oct 2011 22:57:49 +0000 (00:57 +0200)
committerJilles Tjoelker <redacted>
Mon, 3 Oct 2011 22:57:49 +0000 (00:57 +0200)
They are now in messages, even if client_flood_message_time is not 1.

If client_flood_message_time is not 1 (by default it is), this needs a
configuration change to maintain the same behaviour.

modules/m_info.c
src/packet.c

index 0224fa29c543ddb5bfb5390c768fbb9d7da66696..5ee13253caabd929ae1d6078af17ff919f6725b8 100644 (file)
@@ -131,13 +131,13 @@ static struct InfoStruct info_table[] = {
                "client_flood_burst_rate",
                OUTPUT_DECIMAL,
                &ConfigFileEntry.client_flood_burst_rate,
-               "Maximum lines per second during flood grace period, times client_flood_message_time",
+               "Maximum lines per second during flood grace period",
        },
        {
                "client_flood_burst_max",
                OUTPUT_DECIMAL,
                &ConfigFileEntry.client_flood_burst_max,
-               "Number of lines to process at once before delaying, times client_flood_message_time",
+               "Number of lines to process at once before delaying",
        },
        {
                "client_flood_message_num",
index d6988aebfe516284e9680f90d7bbaf47c171d25e..0fe061a7d6cd5020da9101569bb925c3fd5f4e25 100644 (file)
@@ -101,6 +101,7 @@ parse_client_queued(struct Client *client_p)
                        allow_read = ConfigFileEntry.client_flood_burst_max;
                else
                        allow_read = ConfigFileEntry.client_flood_burst_rate;
+               allow_read *= ConfigFileEntry.client_flood_message_time;
                /* allow opers 4 times the amount of messages as users. why 4?
                 * why not. :) --fl_
                 */