rtpjitter: Account for rtx_retry in overflow check

As rtx_retry is part of the substraction, we need to take it into
account, otherwise we may endup with a big value.
This commit is contained in:
Nicolas Dufresne 2015-03-20 13:03:09 -04:00
parent d63c163335
commit 12762ad1a5

View file

@ -2063,7 +2063,7 @@ calculate_expected (GstRtpJitterBuffer * jitterbuffer, guint32 expected,
GstClockTime timeout = timer->timeout;
timer->duration = duration;
if (timeout > expected_dts) {
if (timeout > (expected_dts + timer->rtx_retry)) {
GstClockTime delay = timeout - expected_dts - timer->rtx_retry;
reschedule_timer (jitterbuffer, timer, timer->seqnum, expected_dts,
delay, TRUE);