diff options
author | twisted <twisted@f38db490-d61c-443f-a65b-d21fe96a405b> | 2005-11-30 03:35:24 +0000 |
---|---|---|
committer | twisted <twisted@f38db490-d61c-443f-a65b-d21fe96a405b> | 2005-11-30 03:35:24 +0000 |
commit | ae48a402d8796f824afe07829ce67aecf216e448 (patch) | |
tree | e9c8c4396f220ad22056a5e7e57ddeaa2787116d /apps | |
parent | dd5cbe502332ab46445c0c71e265d84966bd657c (diff) |
issue #5887
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@7225 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'apps')
-rw-r--r-- | apps/app_voicemail.c | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/apps/app_voicemail.c b/apps/app_voicemail.c index 2f9c515c8..2dab9fac0 100644 --- a/apps/app_voicemail.c +++ b/apps/app_voicemail.c @@ -573,8 +573,12 @@ static struct ast_vm_user *find_user(struct ast_vm_user *ivm, const char *contex struct ast_vm_user *vmu=NULL, *cur; ast_mutex_lock(&vmlock); cur = users; + + if (!context) + context = "default"; + while (cur) { - if ((!context || !strcasecmp(context, cur->context)) && + if ((!strcasecmp(context, cur->context)) && (!strcasecmp(mailbox, cur->mailbox))) break; cur=cur->next; @@ -4985,7 +4989,7 @@ static int vm_authenticate(struct ast_channel *chan, char *mailbox, int mailbox_ valid++; else { if (option_verbose > 2) - ast_verbose( VERBOSE_PREFIX_3 "Incorrect password '%s' for user '%s' (context = %s)\n", password, mailbox, context ? context : "<any>"); + ast_verbose( VERBOSE_PREFIX_3 "Incorrect password '%s' for user '%s' (context = %s)\n", password, mailbox, context ? context : "default"); if (!ast_strlen_zero(prefix)) mailbox[0] = '\0'; } |