diff -r 7510455a1902 -r bba8505129d5 libpurple/protocols/jabber/jingle/rtp.c --- a/libpurple/protocols/jabber/jingle/rtp.c Tue Feb 04 02:59:47 2020 +0000 +++ b/libpurple/protocols/jabber/jingle/rtp.c Tue Feb 04 03:05:18 2020 +0000 @@ -87,9 +87,12 @@ for (; candidates; candidates = g_list_next(candidates)) { PurpleMediaCandidate *candidate = candidates->data; - gchar *id = jabber_get_next_id(jingle_session_get_js(session)); - jingle_transport_add_local_candidate(transport, id, generation, candidate); - g_free(id); + if (purple_media_candidate_get_protocol(candidate) == + PURPLE_MEDIA_NETWORK_PROTOCOL_UDP) { + gchar *id = jabber_get_next_id(jingle_session_get_js(session)); + jingle_transport_add_local_candidate(transport, id, generation, candidate); + g_free(id); + } } return transport; @@ -217,8 +220,15 @@ session); g_object_unref(session); - } else if (type == PURPLE_MEDIA_INFO_ACCEPT && + /* The same signal is emited *four* times in case of acceptance + * by purple_media_stream_info() (stream acceptance, session + * acceptance, participant acceptance, and conference acceptance). + * We only react to the first one, where sid and name are given + * non-null values. + */ + } else if (type == PURPLE_MEDIA_INFO_ACCEPT && sid && name && jingle_session_is_initiator(session) == FALSE) { + jingle_rtp_ready(session); } }