]> git.ipfire.org Git - thirdparty/asterisk.git/commit
res_rtp_asterisk: Don't count 0 as a minimum lost packets
authorKevin Harwell <kharwell@sangoma.com>
Mon, 29 Mar 2021 22:40:49 +0000 (17:40 -0500)
committerKevin Harwell <kharwell@digium.com>
Wed, 31 Mar 2021 20:08:38 +0000 (15:08 -0500)
commit0ad1ff8a72ab1e653944de7f08ea60a39cacb96e
tree3104bd9c4daf2b10ef781d915741708c85cbe8fd
parent1414b9cc576138d9f286f536852b8d158d89d5a5
res_rtp_asterisk: Don't count 0 as a minimum lost packets

The calculated minimum lost packets represents the lowest number of
lost packets missed during an RTCP report interval. Zero of course
is the lowest, but the idea is that this value contain the lowest
number of lost packets once some have been missed.

This patch checks to make sure the number of lost packets over an
interval is not zero before checking and setting the minimum value.

Also, this patch updates the rtp lost packet test to check for
packet loss over several reports vs one.

Change-Id: I07d6e21cec61e289c2326138d6bcbcb3c3d5e008
res/res_rtp_asterisk.c
tests/test_res_rtp.c