From 321e662b882ab59b4c897bb9ad975decb1eb426e Mon Sep 17 00:00:00 2001 From: Anthony Minessale Date: Wed, 27 Feb 2008 17:06:25 +0000 Subject: [PATCH] tweak git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@7755 d0543943-73ff-0310-b7d9-9358b9ac24b2 --- src/mod/endpoints/mod_sofia/sofia.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/mod/endpoints/mod_sofia/sofia.c b/src/mod/endpoints/mod_sofia/sofia.c index 732f1ad5a6..609530b5f7 100644 --- a/src/mod/endpoints/mod_sofia/sofia.c +++ b/src/mod/endpoints/mod_sofia/sofia.c @@ -224,6 +224,11 @@ void sofia_event_callback(nua_event_t event, if (session) { switch_core_session_signal_lock(session); + + if (channel && switch_channel_get_state(channel) >= CS_HANGUP) { + switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_DEBUG, "Channel is already hungup.\n"); + goto done; + } } if ((profile->pflags & PFLAG_AUTH_ALL) && tech_pvt && tech_pvt->key && sip) {