diff options
Diffstat (limited to 'src/server/sv_main.c')
-rw-r--r-- | src/server/sv_main.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/server/sv_main.c b/src/server/sv_main.c index 0c4c7f46..16bae3ab 100644 --- a/src/server/sv_main.c +++ b/src/server/sv_main.c @@ -1181,7 +1181,10 @@ int SV_RateMsec(client_t *client) else messageSize += UDPIP_HEADER_SIZE; - rateMsec = messageSize * 1000 / ((int) (rate * com_timescale->value)); + rate = (int)(rate * com_timescale->value); + if(rate < 1) + rate = 1; + rateMsec = messageSize * 1000 / rate; rate = Sys_Milliseconds() - client->netchan.lastSentTime; if(rate > rateMsec) |