Modified: freeswitch/trunk/src/switch_ivr_originate.c (14649 => 14650)
--- freeswitch/trunk/src/switch_ivr_originate.c 2009-08-27 16:07:36 UTC (rev 14649)
+++ freeswitch/trunk/src/switch_ivr_originate.c 2009-08-27 16:43:55 UTC (rev 14650)
@@ -1893,7 +1893,7 @@
switch_dtmf_t dtmf = { 0, 0 };
if (switch_channel_dequeue_dtmf(caller_channel, &dtmf) == SWITCH_STATUS_SUCCESS) {
if (dtmf.digit == *cancel_key) {
- oglobals.idx = IDX_TIMEOUT;
+ oglobals.idx = IDX_CANCEL;
goto notready;
}
}
@@ -2014,10 +2014,9 @@
if (switch_channel_up(originate_status[i].peer_channel)) {
if (caller_channel && i == 0) {
holding = switch_channel_get_variable(caller_channel, SWITCH_HOLDING_UUID_VARIABLE);
- holding = switch_core_session_strdup(oglobals.session, holding);
switch_channel_set_variable(caller_channel, SWITCH_HOLDING_UUID_VARIABLE, NULL);
}
- if (holding) {
+ if (holding && oglobals.idx != IDX_TIMEOUT && oglobals.idx != IDX_CANCEL) {
switch_ivr_uuid_bridge(holding, switch_core_session_get_uuid(originate_status[i].peer_session));
} else {
switch_channel_hangup(originate_status[i].peer_channel, reason);