diff options
author | Miguel París Díaz <mparisdiaz@gmail.com> | 2014-10-20 13:00:37 +0200 |
---|---|---|
committer | Tim-Philipp Müller <tim@centricular.com> | 2014-11-22 14:48:57 +0000 |
commit | 6daa57868f01da46aa2c6cfc0a4dc8344312e4c1 (patch) | |
tree | cff25c43306b19cbfde61e0391e7d8f128fe317d | |
parent | ad4480d53408a4d97ab531174ef37f258f3253c0 (diff) |
rtpjitterbuffer: ensure rtx_retry_period >= 0
https://bugzilla.gnome.org/show_bug.cgi?id=739344
-rw-r--r-- | gst/rtpmanager/gstrtpjitterbuffer.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/gst/rtpmanager/gstrtpjitterbuffer.c b/gst/rtpmanager/gstrtpjitterbuffer.c index 81bb1856c..3695e1562 100644 --- a/gst/rtpmanager/gstrtpjitterbuffer.c +++ b/gst/rtpmanager/gstrtpjitterbuffer.c @@ -2743,7 +2743,11 @@ get_rtx_retry_period (GstRtpJitterBufferPrivate * priv, if (priv->rtx_retry_period == -1) { /* we retry up to the configured jitterbuffer size but leaving some * room for the retransmission to arrive in time */ - rtx_retry_period = priv->latency_ns - rtx_retry_timeout; + if (rtx_retry_timeout > priv->latency_ns) { + rtx_retry_period = 0; + } else { + rtx_retry_period = priv->latency_ns - rtx_retry_timeout; + } } else { rtx_retry_period = priv->rtx_retry_period * GST_MSECOND; } |