[Freeswitch-svn] [commit] r4954 - freeswitch/trunk/src/mod/endpoints/mod_wanpipe
Freeswitch SVN
anthm at freeswitch.org
Mon Apr 16 21:26:13 EDT 2007
Author: anthm
Date: Mon Apr 16 21:26:13 2007
New Revision: 4954
Modified:
freeswitch/trunk/src/mod/endpoints/mod_wanpipe/mod_wanpipe.c
Log:
...
Modified: freeswitch/trunk/src/mod/endpoints/mod_wanpipe/mod_wanpipe.c
==============================================================================
--- freeswitch/trunk/src/mod/endpoints/mod_wanpipe/mod_wanpipe.c (original)
+++ freeswitch/trunk/src/mod/endpoints/mod_wanpipe/mod_wanpipe.c Mon Apr 16 21:26:13 2007
@@ -1352,9 +1352,11 @@
assert(channel != NULL);
if (switch_channel_get_state(channel) < CS_HANGUP) {
+
+
tech_pvt = switch_core_session_get_private(session);
assert(tech_pvt != NULL);
-
+ chanmap = tech_pvt->spri->private_info;
if (!tech_pvt->call) {
tech_pvt->call = pevent->hangup.call;
}
@@ -1362,6 +1364,9 @@
tech_pvt->cause = pevent->hangup.cause;
switch_set_flag_locked(tech_pvt, TFLAG_HANGUP);
switch_channel_hangup(channel, tech_pvt->cause);
+ switch_mutex_lock(chanmap->mutex);
+ pri_destroycall(tech_pvt->spri->pri, tech_pvt->call);
+ switch_mutex_unlock(chanmap->mutex);
switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_NOTICE, "-- Hanging up channel s%dc%d\n", spri->span, pevent->hangup.channel);
} else {
switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_NOTICE, "-- Duplicate Hang up on channel s%dc%d\n", spri->span, pevent->hangup.channel);
More information about the Freeswitch-svn
mailing list