mirror of
https://github.com/signalwire/freeswitch.git
synced 2026-07-24 13:12:03 +00:00
prevent race while changing codecs mid call
This commit is contained in:
@@ -2673,6 +2673,7 @@ switch_status_t sofia_glue_tech_set_codec(private_object_t *tech_pvt, int force)
|
||||
switch_core_session_lock_codec_write(tech_pvt->session);
|
||||
switch_core_session_lock_codec_read(tech_pvt->session);
|
||||
resetting = 1;
|
||||
switch_yield(tech_pvt->read_impl.microseconds_per_packet);
|
||||
switch_core_codec_destroy(&tech_pvt->read_codec);
|
||||
switch_core_codec_destroy(&tech_pvt->write_codec);
|
||||
} else {
|
||||
|
||||
Reference in New Issue
Block a user