From 88f18faf2a150b85255ce3010456e4f039956c99 Mon Sep 17 00:00:00 2001
From: George Joseph <gjoseph@digium.com>
Date: Wed, 14 Jun 2017 07:54:45 -0600
Subject: [PATCH] res_rtp_asterisk:  Fix ssrc change for rtcp srtp

It looks like there was a copy/paste error in ast_rtp_change_source
where if there was a rtcp srtp instance, instead of updating its
ssrc we were updating the srtp instance ssrc twice.

ASTERISK-27022 #close
Reported-by: Michael Walton

Change-Id: Ic88f3aee7227b401c58745ac265ff92c19620095
---
 res/res_rtp_asterisk.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/res/res_rtp_asterisk.c b/res/res_rtp_asterisk.c
index c120fc1452..600846c851 100644
--- a/res/res_rtp_asterisk.c
+++ b/res/res_rtp_asterisk.c
@@ -3447,7 +3447,7 @@ static void ast_rtp_change_source(struct ast_rtp_instance *instance)
 		ast_debug(3, "Changing ssrc for SRTP from %u to %u\n", rtp->ssrc, ssrc);
 		res_srtp->change_source(srtp, rtp->ssrc, ssrc);
 		if (rtcp_srtp != srtp) {
-			res_srtp->change_source(srtp, rtp->ssrc, ssrc);
+			res_srtp->change_source(rtcp_srtp, rtp->ssrc, ssrc);
 		}
 	}
 
-- 
GitLab