From 021c9197aec7dcb0a1ab22cf7814e7dd4459bffb Mon Sep 17 00:00:00 2001 From: Dan Bechard Date: Sun, 25 Aug 2024 13:56:01 -0400 Subject: [PATCH] Reset time and stats when resetting an endpoint Signed-off-by: Dan Bechard --- reliable.c | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/reliable.c b/reliable.c index 3396345..45675c8 100644 --- a/reliable.c +++ b/reliable.c @@ -1291,6 +1291,13 @@ void reliable_endpoint_reset( struct reliable_endpoint_t * endpoint ) { reliable_assert( endpoint ); + endpoint->time = 0; + endpoint->rtt = 0; + endpoint->packet_loss = 0; + endpoint->sent_bandwidth_kbps = 0; + endpoint->received_bandwidth_kbps = 0; + endpoint->acked_bandwidth_kbps = 0; + endpoint->num_acks = 0; endpoint->sequence = 0;