Fix bug causing connections not to be updated

next_connections_dump was decremented by a wrong count, which could
cause it to wrap. When this occurred, connections in the GUI where not
updated anymore (new connections not shown, old connections not updated)
This commit is contained in:
emanuele-f 2021-10-24 15:24:41 +02:00
parent 875304b918
commit d93bed560c

View File

@ -375,7 +375,7 @@ conn_data_t* new_connection(vpnproxy_data_t *proxy, const zdtun_5tuple_t *tuple,
// If all the netd connections have been resolved, remove the dump delay
if((--netd_resolve_waiting) == 0) {
log_d("Removing netd resolution delay");
next_connections_dump -= proxy->now_ms;
next_connections_dump -= NETD_RESOLVE_DELAY_MS;
}
}
}