Change in libosmo-abis[master]: osmo_ortp: Fix seqno reset to 0 upon ssrc_changed

pespin gerrit-no-reply at lists.osmocom.org
Tue Jul 20 12:40:08 UTC 2021


pespin has uploaded this change for review. ( https://gerrit.osmocom.org/c/libosmo-abis/+/24966 )


Change subject: osmo_ortp: Fix seqno reset to 0 upon ssrc_changed
......................................................................

osmo_ortp: Fix seqno reset to 0 upon ssrc_changed

It was spotted in an osmo-mgw instance receiving RTP from osmo-bts 1.2.3
that sometimes the seqno was reset to 0 (while tx_timestamp was kept
properly). This seems to be the only possible way osmo-bts can reset the
seqno to 0 (calling rtp_session_reset()), since osmo_rtp_socket_create
already sets it to other values and inside ortp rtp_session_reset() is
the only one setting it to 0.
If SSRC changes, we are fine resetting some Rx state, which is done by
calling rtp_session_resync. However, calling rtp_session_reset() is too
much, since it erases other stuff like Tx state, which sholdn't be
affected in this case, since we are still transmitting the same stream.

Related: OS#3104
Related: OS#3299
Related: SYS#5498
Fixes: 28eeb6bc9365bbe47125775fcb1f696317c22466

Change-Id: Ic6006b4991c85413b009b70f8f3a6f97c41990ec
---
M src/trau/osmo_ortp.c
1 file changed, 2 insertions(+), 2 deletions(-)



  git pull ssh://gerrit.osmocom.org:29418/libosmo-abis refs/changes/66/24966/1

diff --git a/src/trau/osmo_ortp.c b/src/trau/osmo_ortp.c
index b72f681..011f097 100644
--- a/src/trau/osmo_ortp.c
+++ b/src/trau/osmo_ortp.c
@@ -142,8 +142,8 @@
 	uint32_t ssrc = rtp_session_get_recv_ssrc(rs);
 
 	LOGP(DLMIB, LOGL_INFO,
-	     "osmo-ortp(%d): ssrc_changed to 0x%08x, resetting\n", port, ssrc);
-	rtp_session_reset(rs);
+	     "osmo-ortp(%d): ssrc_changed to 0x%08x, resyncing\n", port, ssrc);
+	rtp_session_resync(rs);
 }
 
 static void ortp_sig_cb_pt(RtpSession *rs, void *data)

-- 
To view, visit https://gerrit.osmocom.org/c/libosmo-abis/+/24966
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings

Gerrit-Project: libosmo-abis
Gerrit-Branch: master
Gerrit-Change-Id: Ic6006b4991c85413b009b70f8f3a6f97c41990ec
Gerrit-Change-Number: 24966
Gerrit-PatchSet: 1
Gerrit-Owner: pespin <pespin at sysmocom.de>
Gerrit-MessageType: newchange
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osmocom.org/pipermail/gerrit-log/attachments/20210720/78dec14a/attachment.htm>


More information about the gerrit-log mailing list