[Pkg-voip-commits] [janus] 205/282: Don't use RTCP BYE as DTLS alerts to close PeerConnections

Jonas Smedegaard dr at jones.dk
Wed Dec 20 21:53:41 UTC 2017


This is an automated email from the git hooks/post-receive script.

js pushed a commit to annotated tag debian/0.2.6-1
in repository janus.

commit b0b4bc6358f369b03c47bf546271d83ce8bf16df
Author: Lorenzo Miniero <lminiero at gmail.com>
Date:   Mon Nov 27 17:26:00 2017 +0100

    Don't use RTCP BYE as DTLS alerts to close PeerConnections
---
 ice.c | 18 ++++--------------
 1 file changed, 4 insertions(+), 14 deletions(-)

diff --git a/ice.c b/ice.c
index 0e6ef49..971d399 100644
--- a/ice.c
+++ b/ice.c
@@ -2245,21 +2245,11 @@ static void janus_ice_cb_nice_recv(NiceAgent *agent, guint stream_id, guint comp
 				if(g_atomic_int_get(&handle->dump_packets))
 					janus_text2pcap_dump(handle->text2pcap, JANUS_TEXT2PCAP_RTCP, TRUE, buf, buflen,
 						"[session=%"SCNu64"][handle=%"SCNu64"]", session->session_id, handle->handle_id);
-				/* Check if there's an RTCP BYE: in case, let's wrap up */
+				/* Check if there's an RTCP BYE: in case, let's log it */
 				if(janus_rtcp_has_bye(buf, buflen)) {
-					/* Firefox 52 sends a broken BYE as part of its first compound packet: to
-					 * "fix" this, we check if we got a BYE too soon, and in case ignore it */
-					gint64 now = janus_get_monotonic_time();
-					if(now - component->dtls->dtls_connected < 500000) {
-						JANUS_LOG(LOG_WARN, "[%"SCNu64"] Got RTCP BYE on stream %"SCNu16" (component %"SCNu16"), but it arrived too soon, ignoring...\n",
-							handle->handle_id, stream->stream_id, component->component_id);
-						/* FIXME Should we remove the BYE from the compound packet? */
-					} else {
-						/* Looks like it's a real BYE: hangup the PeerConnection */
-						JANUS_LOG(LOG_VERB, "[%"SCNu64"] Got RTCP BYE on stream %"SCNu16" (component %"SCNu16"), closing...\n", handle->handle_id, stream->stream_id, component->component_id);
-						janus_ice_webrtc_hangup(handle, "RTCP BYE");
-						return;
-					}
+					/* Note: we used to use this as a trigger to close the PeerConnection, but not anymore
+					 * Discussion here, https://groups.google.com/forum/#!topic/meetecho-janus/4XtfbYB7Jvc */
+					JANUS_LOG(LOG_VERB, "[%"SCNu64"] Got RTCP BYE on stream %"SCNu16" (component %"SCNu16")\n", handle->handle_id, stream->stream_id, component->component_id);
 				}
 				/* Is this audio or video? */
 				int video = 0;

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-voip/janus.git



More information about the Pkg-voip-commits mailing list