[Asterisk-code-review] res rtp asterisk: rtp->ice check not wrapped in HAVE PJPROJE... (asterisk[master])

Kevin Harwell asteriskteam at digium.com
Thu Dec 24 10:30:53 CST 2015


Kevin Harwell has uploaded a new change for review.

  https://gerrit.asterisk.org/1852

Change subject: res_rtp_asterisk: rtp->ice check not wrapped in HAVE_PJPROJECT ifdef
......................................................................

res_rtp_asterisk: rtp->ice check not wrapped in HAVE_PJPROJECT ifdef

Change-Id: I19b49112e1b630bd04e859f14ccf96f8ebd6b151
---
M res/res_rtp_asterisk.c
1 file changed, 8 insertions(+), 2 deletions(-)


  git pull ssh://gerrit.asterisk.org:29418/asterisk refs/changes/52/1852/1

diff --git a/res/res_rtp_asterisk.c b/res/res_rtp_asterisk.c
index 1fb4e1c..b4f71e8 100644
--- a/res/res_rtp_asterisk.c
+++ b/res/res_rtp_asterisk.c
@@ -4861,12 +4861,18 @@
 		rtp_learning_seq_init(&rtp->rtp_source_learn, rtp->seqno);
 	}
 
-#ifdef HAVE_OPENSSL_SRTP
 	/* Trigger pending outbound DTLS packets received before the address was set.  Avoid unnecessary locking
 	 * by checking if we're passive. Without this, we only send the pending packets once a new SSL packet is
 	 * received in __rtp_recvfrom.  If rtp->ice, this is instead done on_ice_complete
 	 */
-	if (!rtp->ice && rtp->dtls.dtls_setup == AST_RTP_DTLS_SETUP_PASSIVE) {
+#ifdef HAVE_PJPROJECT
+	if (rtp->ice) {
+		return;
+	}
+#endif
+
+#ifdef HAVE_OPENSSL_SRTP
+	if (rtp->dtls.dtls_setup == AST_RTP_DTLS_SETUP_PASSIVE) {
 		dtls_srtp_flush_pending(instance, rtp);
 	}
 #endif

-- 
To view, visit https://gerrit.asterisk.org/1852
To unsubscribe, visit https://gerrit.asterisk.org/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I19b49112e1b630bd04e859f14ccf96f8ebd6b151
Gerrit-PatchSet: 1
Gerrit-Project: asterisk
Gerrit-Branch: master
Gerrit-Owner: Kevin Harwell <kharwell at digium.com>



More information about the asterisk-code-review mailing list