mirror of
https://github.com/signalwire/freeswitch.git
synced 2026-07-23 20:51:58 +00:00
[Core] Add new switch_core_session_try_reset() API to fix a deadlock for the case when two threads want to set session codecs.
This commit is contained in:
@@ -1359,6 +1359,14 @@ SWITCH_DECLARE(switch_status_t) switch_core_session_set_video_write_impl(switch_
|
||||
*/
|
||||
SWITCH_DECLARE(void) switch_core_session_reset(_In_ switch_core_session_t *session, switch_bool_t flush_dtmf, switch_bool_t reset_read_codec);
|
||||
|
||||
/*!
|
||||
\brief Reset the buffers and resampler on a session, fail if can not lock codec mutexes
|
||||
\param session the session to reset
|
||||
\param flush_dtmf flush all queued dtmf events too
|
||||
\return SWITCH_STATUS_SUCCESS if the session was reset
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status_t) switch_core_session_try_reset(switch_core_session_t* session, switch_bool_t flush_dtmf, switch_bool_t reset_read_codec);
|
||||
|
||||
/*!
|
||||
\brief Write a frame to a session
|
||||
\param session the session to write to
|
||||
|
||||
Reference in New Issue
Block a user