Index: app_voicemail.c =================================================================== --- app_voicemail.c (revision 48639) +++ app_voicemail.c (working copy) @@ -312,6 +312,7 @@ unsigned int flags; /*!< VM_ flags */ int saydurationm; int maxmsg; /*!< Maximum number of msgs per folder for this mailbox */ + int vmmaxmessage; /*!< Maximum number of seconds per message for this mailbox */ #ifdef IMAP_STORAGE char imapuser[80]; /* IMAP server login */ char imappassword[80]; /* IMAP server password if authpassword not defined */ @@ -561,6 +562,8 @@ ast_copy_string(vmu->dialout, dialcontext, sizeof(vmu->dialout)); if (exitcontext) ast_copy_string(vmu->exit, exitcontext, sizeof(vmu->exit)); + if (vmmaxmessage) + vmu->vmmaxmessage = vmmaxmessage; if (maxmsg) vmu->maxmsg = maxmsg; vmu->volgain = volgain; @@ -617,6 +620,13 @@ ast_copy_string(vmu->dialout, value, sizeof(vmu->dialout)); } else if (!strcasecmp(var, "exitcontext")) { ast_copy_string(vmu->exit, value, sizeof(vmu->exit)); + } else if (!strcasecmp(var, "maxmessage")) { + if (vmu->vmmaxmessage <= 0) { + ast_log(LOG_WARNING, "Invalid max message length of %s. Using global value %i\n",value,vmmaxmessage); + vmu->vmmaxmessage = vmmaxmessage; + } else { + vmu->vmmaxmessage = atoi(value); + } } else if (!strcasecmp(var, "maxmsg")) { vmu->maxmsg = atoi(value); if (vmu->maxmsg <= 0) { @@ -668,6 +678,7 @@ struct ast_variable *tmp; tmp = var; while (tmp) { + ast_log(LOG_DEBUG, "Name: %s Value: %s\n",tmp->name,tmp->value); if (!strcasecmp(tmp->name, "password")) { ast_copy_string(retval->password, tmp->value, sizeof(retval->password)); } else if (!strcasecmp(tmp->name, "uniqueid")) {