aboutsummaryrefslogtreecommitdiffstats
path: root/tests/jibuf/jibuf_tool.c
diff options
context:
space:
mode:
Diffstat (limited to 'tests/jibuf/jibuf_tool.c')
-rw-r--r--tests/jibuf/jibuf_tool.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/tests/jibuf/jibuf_tool.c b/tests/jibuf/jibuf_tool.c
index 78eece0..4a35a94 100644
--- a/tests/jibuf/jibuf_tool.c
+++ b/tests/jibuf/jibuf_tool.c
@@ -214,7 +214,9 @@ void dequeue_cb(struct msgb *msg, void *data)
gettimeofday(&pinfo->postqueue.ts, NULL);
pinfo->postqueue.timestamp = htonl(rtph->timestamp);
- if (postqueue_started) {
+ /* If pkt->marker -> init of talkspurt, there may be missing packets before,
+ * better to start calculating the jitter from here */
+ if (postqueue_started && !rtph->marker) {
/* In random test mode we now the sender time, so we get real
* jitter results using it */
if(opt_test_rand) {
@@ -265,7 +267,9 @@ void pkt_arrived_cb(void *data)
gettimeofday(&pinfo->prequeue.ts, NULL);
pinfo->prequeue.timestamp = htonl(rtph->timestamp);
- if (prequeue_started) {
+ /* If pkt->marker -> init of talkspurt, there may be missing packets before,
+ * better to start calculating the jitter from here */
+ if (prequeue_started && !rtph->marker) {
/* In random test mode we now the sender time, so we get real
* jitter results using it */
if(opt_test_rand) {