Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/mod/endpoints/mod_sofia/mod_sofia.c
Original file line number Diff line number Diff line change
Expand Up @@ -679,7 +679,7 @@ switch_status_t sofia_on_hangup(switch_core_session_t *session)

sofia_clear_flag(tech_pvt, TFLAG_IO);

if (tech_pvt->sofia_private) {
if (tech_pvt->nh && tech_pvt->sofia_private) {
/* set to NULL so that switch_core_session_locate no longer succeeds, but don't lose the UUID in uuid_str so we
* can fire events with session UUID */
tech_pvt->sofia_private->uuid = NULL;
Expand Down
2 changes: 2 additions & 0 deletions src/mod/endpoints/mod_sofia/sofia.c
Original file line number Diff line number Diff line change
Expand Up @@ -2161,6 +2161,8 @@ static void our_sofia_event_callback(nua_event_t event,

if (tech_pvt && (tech_pvt->nh == nh)) {
tech_pvt->nh = NULL;
/* Sofia private is allocated from nh's pool. If it will be destroyed, we need to clear it */
tech_pvt->sofia_private = NULL;
}

nua_handle_destroy(nh);
Expand Down