fix: packet lost calcul

This commit is contained in:
2025-12-16 07:07:45 -06:00
parent 0c5dfbb9b4
commit 1cd2ae4ed0

View File

@@ -47,9 +47,8 @@ void print_statistics(struct statistics const *stats, struct setting const *sett
printf("%zu packets transmitted, %zu packets received, %.3f%% packet loss\n",
stats->packets_sent,
stats->packets_received,
(double) stats->packets_received * 100 / (double) stats->packets_sent
((double) stats->packets_sent - stats->packets_received) * 100 / stats->packets_sent
);
// TODO fix packet lost calcul
}
static const char *get_message_description(const uint8_t type, const uint8_t code)