Commit 3c1650c5 authored by Mickaël Turnel's avatar Mickaël Turnel

Fix async rtp thread queue not initialized when not in windows

parent f0e1ac6c
...@@ -313,9 +313,9 @@ rtp_session_init (RtpSession * session, int mode) ...@@ -313,9 +313,9 @@ rtp_session_init (RtpSession * session, int mode)
#if defined(_WIN32) || defined(_WIN32_WCE) #if defined(_WIN32) || defined(_WIN32_WCE)
session->rtp.is_win_thread_running = FALSE; session->rtp.is_win_thread_running = FALSE;
qinit(&session->rtp.winrq);
ortp_mutex_init(&session->rtp.winrq_lock, NULL); ortp_mutex_init(&session->rtp.winrq_lock, NULL);
#endif #endif
qinit(&session->rtp.winrq);
} }
void rtp_session_enable_congestion_detection(RtpSession *session, bool_t enabled){ void rtp_session_enable_congestion_detection(RtpSession *session, bool_t enabled){
...@@ -1566,11 +1566,13 @@ static void ortp_stream_uninit(OrtpStream *os){ ...@@ -1566,11 +1566,13 @@ static void ortp_stream_uninit(OrtpStream *os){
void rtp_session_uninit (RtpSession * session) void rtp_session_uninit (RtpSession * session)
{ {
#if defined(_WIN32) || defined(_WIN32_WCE) #if defined(_WIN32) || defined(_WIN32_WCE)
session->rtp.is_win_thread_running = FALSE; if (session->rtp.is_win_thread_running) {
ortp_thread_join(session->rtp.win_t, NULL); session->rtp.is_win_thread_running = FALSE;
flushq(&session->rtp.winrq, FLUSHALL); ortp_thread_join(session->rtp.win_t, NULL);
}
ortp_mutex_destroy(&session->rtp.winrq_lock); ortp_mutex_destroy(&session->rtp.winrq_lock);
#endif #endif
flushq(&session->rtp.winrq, FLUSHALL);
RtpTransport *rtp_meta_transport = NULL; RtpTransport *rtp_meta_transport = NULL;
RtpTransport *rtcp_meta_transport = NULL; RtpTransport *rtcp_meta_transport = NULL;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment