From 9bf0e8c517ea5013c7425ff9de7d731f59f2e56f Mon Sep 17 00:00:00 2001 From: Anthony Minessale Date: Fri, 2 May 2014 00:00:13 +0500 Subject: [PATCH] FS-6503 --resolve remove unused code --- src/mod/applications/mod_voicemail/mod_voicemail.c | 13 ------------- 1 file changed, 13 deletions(-) diff --git a/src/mod/applications/mod_voicemail/mod_voicemail.c b/src/mod/applications/mod_voicemail/mod_voicemail.c index 7a4bf67a48..a9ff0a2ec3 100644 --- a/src/mod/applications/mod_voicemail/mod_voicemail.c +++ b/src/mod/applications/mod_voicemail/mod_voicemail.c @@ -3357,7 +3357,6 @@ static switch_status_t voicemail_leave_main(switch_core_session_t *session, vm_p switch_input_args_t args = { 0 }; char *vm_email = NULL; char *vm_notify_email = NULL; - int send_mail = 0; cc_t cc = { 0 }; char *read_flags = NORMAL_FLAG_STRING; const char *operator_ext = switch_channel_get_variable(channel, "vm_operator_extension"); @@ -3419,8 +3418,6 @@ static switch_status_t voicemail_leave_main(switch_core_session_t *session, vm_p skip_instructions = switch_true(val); } else if (!strcasecmp(var, "email-addr")) { email_addr = switch_core_session_strdup(session, val); - } else if (!strcasecmp(var, "vm-email-all-messages") && (send_main = switch_true(val))) { - send_mail++; } else if (!strcasecmp(var, "vm-storage-dir")) { vm_storage_dir = switch_core_session_strdup(session, val); } else if (!strcasecmp(var, "vm-domain-storage-dir")) { @@ -3429,8 +3426,6 @@ static switch_status_t voicemail_leave_main(switch_core_session_t *session, vm_p switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH_LOG_WARNING, "Using deprecated 'storage-dir' directory variable: Please use 'vm-domain-storage-dir'.\n"); storage_dir = switch_core_session_strdup(session, val); - } else if (!strcasecmp(var, "vm-notify-email-all-messages") && (send_notify = switch_true(val))) { - send_mail++; } else if (!strcasecmp(var, "vm-disk-quota")) { disk_quota = atoi(val); } else if (!strcasecmp(var, "vm-alternate-greet-id")) { @@ -3466,12 +3461,6 @@ static switch_status_t voicemail_leave_main(switch_core_session_t *session, vm_p } } - if (send_mail && (!(send_main || send_notify))) { - switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH_LOG_WARNING, - "Falling back to leaving message locally due to too many misconfiguration.\n"); - send_mail = 0; - } - } else { switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH_LOG_WARNING, "Can't find user [%s@%s]\n", id, domain_name); ok = 0; @@ -3578,7 +3567,6 @@ static switch_status_t voicemail_leave_main(switch_core_session_t *session, vm_p if (argc >= 1 && argc <= 4) { switch_ivr_session_transfer(session, argv[0], argv[1], argv[2]); /* the application still runs after we leave it so we need to make sure that we don't do anything evil */ - send_mail = 0; goto end; } } @@ -3592,7 +3580,6 @@ static switch_status_t voicemail_leave_main(switch_core_session_t *session, vm_p if (argc >= 1 && argc <= 4) { switch_ivr_session_transfer(session, argv[0], argv[1], argv[2]); /* the application still runs after we leave it so we need to make sure that we don't do anything evil */ - send_mail = 0; goto end; } } -- 2.47.2