From eb206003d5d8d18eaa8defb90ebc27d5a83fbde0 Mon Sep 17 00:00:00 2001 From: Alexander Malaev Date: Mon, 28 Oct 2024 16:52:50 +0300 Subject: [PATCH] Fix possible deadlock on udp socket opening error on rtp_forward (#3468) Co-authored-by: Alexander Malaev --- src/plugins/janus_videoroom.c | 1 + 1 file changed, 1 insertion(+) diff --git a/src/plugins/janus_videoroom.c b/src/plugins/janus_videoroom.c index 31f8cecbca..e82a0d65ba 100644 --- a/src/plugins/janus_videoroom.c +++ b/src/plugins/janus_videoroom.c @@ -5867,6 +5867,7 @@ static json_t *janus_videoroom_process_synchronous_request(janus_videoroom_sessi if(publisher->udp_sock <= 0 || (!ipv6_disabled && setsockopt(publisher->udp_sock, IPPROTO_IPV6, IPV6_V6ONLY, &v6only, sizeof(v6only)) != 0)) { janus_mutex_unlock(&publisher->rtp_forwarders_mutex); + janus_mutex_unlock(&publisher->streams_mutex); janus_refcount_decrease(&publisher->ref); janus_mutex_unlock(&videoroom->mutex); janus_refcount_decrease(&videoroom->ref);