summaryrefslogtreecommitdiff
path: root/pjsip
diff options
context:
space:
mode:
authorBenny Prijono <bennylp@teluu.com>2006-06-29 09:41:34 +0000
committerBenny Prijono <bennylp@teluu.com>2006-06-29 09:41:34 +0000
commite11298d219b4fa80862e5cc3f04040ce4c9ac661 (patch)
treea650394244e4b7c203e9f52e110640687a313088 /pjsip
parent72a1098e21f5b7d797655afe7ddb275969a192bd (diff)
Fixed minor bug in the display of packet loss percentage
git-svn-id: http://svn.pjsip.org/repos/pjproject/trunk@565 74dad513-b988-da41-8d7b-12977e46ad98
Diffstat (limited to 'pjsip')
-rw-r--r--pjsip/src/pjsua-lib/pjsua_call.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/pjsip/src/pjsua-lib/pjsua_call.c b/pjsip/src/pjsua-lib/pjsua_call.c
index a745f76a..9e411044 100644
--- a/pjsip/src/pjsua-lib/pjsua_call.c
+++ b/pjsip/src/pjsua-lib/pjsua_call.c
@@ -1302,11 +1302,11 @@ static void dump_media_session(const char *indent,
good_number(ipbytes, stat.rx.bytes + stat.rx.pkt * 32),
indent,
stat.rx.loss,
- stat.rx.loss * 100.0 / stat.rx.pkt,
+ stat.rx.loss * 100.0 / (stat.rx.pkt + stat.rx.loss),
stat.rx.dup,
- stat.rx.dup * 100.0 / stat.rx.pkt,
+ stat.rx.dup * 100.0 / (stat.rx.pkt + stat.rx.dup),
stat.rx.reorder,
- stat.rx.reorder * 100.0 / stat.rx.pkt,
+ stat.rx.reorder * 100.0 / (stat.rx.pkt + stat.rx.reorder),
indent, indent,
stat.rx.loss_period.min / 1000.0,
stat.rx.loss_period.avg / 1000.0,
@@ -1361,11 +1361,11 @@ static void dump_media_session(const char *indent,
indent,
stat.tx.loss,
- stat.tx.loss * 100.0 / stat.tx.pkt,
+ stat.tx.loss * 100.0 / (stat.tx.pkt + stat.tx.loss),
stat.tx.dup,
- stat.tx.dup * 100.0 / stat.tx.pkt,
+ stat.tx.dup * 100.0 / (stat.tx.pkt + stat.tx.dup),
stat.tx.reorder,
- stat.tx.reorder * 100.0 / stat.tx.pkt,
+ stat.tx.reorder * 100.0 / (stat.tx.pkt + stat.tx.reorder),
indent, indent,
stat.tx.loss_period.min / 1000.0,