From 37d566c6f6838a82efe55fa06811170e9cccb805 Mon Sep 17 00:00:00 2001 From: Ken Rice Date: Wed, 13 Nov 2013 11:14:34 -0600 Subject: [PATCH] FS-5943 --resolve --- src/mod/applications/mod_voicemail/mod_voicemail.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/mod/applications/mod_voicemail/mod_voicemail.c b/src/mod/applications/mod_voicemail/mod_voicemail.c index 07d4d2fe95..6f2e5d68c9 100644 --- a/src/mod/applications/mod_voicemail/mod_voicemail.c +++ b/src/mod/applications/mod_voicemail/mod_voicemail.c @@ -28,6 +28,7 @@ * John Wehle (john@feith.com) * Raymond Chandler * Kristin King + * Emmanuel Schmidbauer * * mod_voicemail.c -- Voicemail Module * @@ -3345,7 +3346,7 @@ static switch_status_t voicemail_leave_main(switch_core_session_t *session, vm_p int send_mail = 0; cc_t cc = { 0 }; char *read_flags = NORMAL_FLAG_STRING; - char *operator_ext = NULL; + const char *operator_ext = switch_channel_get_variable(channel, "vm_operator_extension"); char buf[2]; char key_buf[80]; char *greet_path = NULL; @@ -3422,7 +3423,7 @@ static switch_status_t voicemail_leave_main(switch_core_session_t *session, vm_p vm_enabled = !switch_false(val); } else if (!strcasecmp(var, "vm-message-ext")) { vm_ext = switch_core_session_strdup(session, val); - } else if (!strcasecmp(var, "vm-operator-extension")) { + } else if (!strcasecmp(var, "vm-operator-extension") && (zstr(operator_ext))) { operator_ext = switch_core_session_strdup(session, val); } }