summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorSander Vrijders <sander.vrijders@ugent.be>2017-04-01 14:56:22 +0000
committerdimitri staessens <dimitri.staessens@ugent.be>2017-04-01 14:56:22 +0000
commite244f66d44575c2bb0242ff1c31c0d21ad4a6911 (patch)
tree1baed151ae6ea07eae8a1ca960aadbc3ea115635 /src
parent2725780520d0e2c6a2c49ac8e2124b5088cbe1bb (diff)
parent4d4f065e37fca873aa27a55a293ad0e13136d92e (diff)
downloadouroboros-e244f66d44575c2bb0242ff1c31c0d21ad4a6911.tar.gz
ouroboros-e244f66d44575c2bb0242ff1c31c0d21ad4a6911.zip
Merged in sandervrijders/ouroboros/be-oping-fix (pull request #449)
tools: oping: Fix bad calculation
Diffstat (limited to 'src')
-rw-r--r--src/tools/oping/oping_client.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/tools/oping/oping_client.c b/src/tools/oping/oping_client.c
index 77a08db7..43f402a2 100644
--- a/src/tools/oping/oping_client.c
+++ b/src/tools/oping/oping_client.c
@@ -234,7 +234,7 @@ int client_main(void)
printf("%d SDUs transmitted, ", client.sent);
printf("%d received, ", client.rcvd);
printf("%d%% packet loss, ", client.sent == 0 ? 0 :
- 100 - ((100 * client.rcvd) / client.sent));
+ 100 - (100 * (client.rcvd / client.sent)));
printf("time: %.3f ms\n", ts_diff_us(&tic, &toc) / 1000.0);
if (client.rcvd > 0) {