ortp: reset rtp session on SSRC changes

When libortp detects a timestamp jump, we resynchronize the session
in order to restore proper rtp frame reception. However, we do not
resynchronize on an SSRC change. An SSRC change usually indicates
the change of an RTP stream source, which is a much more profound
event than a timestamp change, so we should even reset the session
on SSRC changes.

Also, not resynchronizing the session on an SSRC change causes
problems when the jitter buffer feature is used. In those cases
it takes libortp a long time until it finally detects the timestamp
jump and the session resyhcornization happens late.

- reset the ession on SSRC changes by calling rtp_session_reset()

Change-Id: I8688a55cd20d0e14493c357db80754851e12f2fb
Related OS#3299
This commit is contained in:
Philipp Maier 2018-05-30 10:52:41 +02:00
parent 7632278ea3
commit 28eeb6bc93
1 changed files with 2 additions and 1 deletions

View File

@ -114,7 +114,8 @@ static void ortp_sig_cb_ssrc(RtpSession *rs, void *data)
uint32_t ssrc = rtp_session_get_recv_ssrc(rs);
LOGP(DLMIB, LOGL_INFO,
"osmo-ortp(%d): ssrc_changed to 0x%08x\n", port, ssrc);
"osmo-ortp(%d): ssrc_changed to 0x%08x, resetting\n", port, ssrc);
rtp_session_reset(rs);
}
static void ortp_sig_cb_pt(RtpSession *rs, void *data)