Fix handling of unsigned types
This commit is contained in:
parent
3f8a6d7b39
commit
1a6a0d5a8b
@ -2330,7 +2330,7 @@ void execute_ip_ban(uint32_t client_ip, map_element speed_element, unsigned int
|
||||
}
|
||||
|
||||
// Detect attack direction with simple heuristic
|
||||
if (abs(int(in_pps - out_pps)) < 1000) {
|
||||
if (abs(int((int)in_pps - (int)out_pps)) < 1000) {
|
||||
// If difference between pps speed is so small we should do additional investigation using bandwidth speed
|
||||
if (in_bps > out_bps) {
|
||||
data_direction = INCOMING;
|
||||
|
Loading…
Reference in New Issue
Block a user