diff --git a/src/mod/endpoints/mod_skinny/mod_skinny.c b/src/mod/endpoints/mod_skinny/mod_skinny.c index 335edaaa6f..7062bd2e4c 100644 --- a/src/mod/endpoints/mod_skinny/mod_skinny.c +++ b/src/mod/endpoints/mod_skinny/mod_skinny.c @@ -756,7 +756,7 @@ int channel_on_hangup_callback(void *pArg, int argc, char **argv, char **columnN skinny_profile_find_listener_by_device_name_and_instance(helper->tech_pvt->profile, device_name, device_instance, &listener); if(listener) { - if(call_state == SKINNY_CONNECTED) { + if((call_state == SKINNY_PROCEED) || (call_state == SKINNY_CONNECTED)) { /* calling parties */ send_stop_tone(listener, line_instance, call_id); } send_set_lamp(listener, SKINNY_BUTTON_LINE, line_instance, SKINNY_LAMP_OFF); @@ -776,7 +776,7 @@ int channel_on_hangup_callback(void *pArg, int argc, char **argv, char **columnN default: send_display_prompt_status(listener, 0, switch_channel_cause2str(helper->cause), line_instance, call_id); } - if(call_state == SKINNY_CONNECTED) { /* calling parties */ + if((call_state == SKINNY_PROCEED) || (call_state == SKINNY_CONNECTED)) { /* calling parties */ skinny_session_stop_media(helper->tech_pvt->session, listener, line_instance); } diff --git a/src/mod/endpoints/mod_skinny/skinny_server.c b/src/mod/endpoints/mod_skinny/skinny_server.c index e3c112b531..56decd0036 100644 --- a/src/mod/endpoints/mod_skinny/skinny_server.c +++ b/src/mod/endpoints/mod_skinny/skinny_server.c @@ -898,8 +898,8 @@ switch_status_t skinny_hold_active_calls(listener_t *listener) "ON skinny_active_lines.device_name = skinny_lines.device_name " "AND skinny_active_lines.device_instance = skinny_lines.device_instance " "AND skinny_active_lines.line_instance = skinny_lines.line_instance " - "WHERE skinny_lines.device_name='%s' AND skinny_lines.device_instance=%d AND call_state=%d", - listener->device_name, listener->device_instance, SKINNY_CONNECTED))) { + "WHERE skinny_lines.device_name='%s' AND skinny_lines.device_instance=%d AND (call_state=%d OR call_state=%d)", + listener->device_name, listener->device_instance, SKINNY_PROCEED, SKINNY_CONNECTED))) { skinny_execute_sql_callback(listener->profile, listener->profile->sql_mutex, sql, skinny_hold_active_calls_callback, &helper); switch_safe_free(sql); }