mirror of
https://github.com/signalwire/freeswitch.git
synced 2025-06-04 12:21:54 +00:00
Seems having a read lock still prevents a write lock to be taken, even if the thread that is trying to get the write lock currently has the read lock.
This commit is contained in:
parent
8d370ff6e6
commit
1ff548f24c
@ -838,6 +838,7 @@ switch_status_t rtmp_session_destroy(rtmp_session_t **rsession)
|
|||||||
|
|
||||||
/* At this point we don't know if the session still exists, so request a fresh pointer to it from the core. */
|
/* At this point we don't know if the session still exists, so request a fresh pointer to it from the core. */
|
||||||
if ( (session = switch_core_session_locate((char *)key)) != NULL ) {
|
if ( (session = switch_core_session_locate((char *)key)) != NULL ) {
|
||||||
|
switch_core_session_rwunlock(session);
|
||||||
switch_core_session_write_lock(session);
|
switch_core_session_write_lock(session);
|
||||||
channel = switch_core_session_get_channel(session);
|
channel = switch_core_session_get_channel(session);
|
||||||
tech_pvt = switch_core_session_get_private(session);
|
tech_pvt = switch_core_session_get_private(session);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user