From: Mark Spencer Date: Mon, 8 Dec 2003 19:31:56 +0000 (+0000) Subject: Path fix for hasnewvoicmeail app X-Git-Tag: 0.7.0~173 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=2fe1bc2e713e4d2e92e5f73a18561f02a63f94b5;p=thirdparty%2Fasterisk.git Path fix for hasnewvoicmeail app git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@1839 65c4cc65-6c06-0410-ace0-fbb531ad65f3 --- diff --git a/apps/app_hasnewvoicemail.c b/apps/app_hasnewvoicemail.c index 10f7914316..f1b055b71c 100755 --- a/apps/app_hasnewvoicemail.c +++ b/apps/app_hasnewvoicemail.c @@ -42,6 +42,7 @@ #include +#include "../astconf.h" static char *tdesc = "Indicator for whether a voice mailbox has new messages."; static char *app_hasnewvoicemail = "HasNewVoicemail"; @@ -82,7 +83,7 @@ static int hasnewvoicemail_exec(struct ast_channel *chan, void *data) vmbox = strsep(&context,"@"); } - snprintf(vmpath,255,ASTSPOOLDIR "/voicemail/%s/%s/INBOX", context, vmbox); + snprintf(vmpath,sizeof(vmpath), "%s/voicemail/%s/%s/INBOX", (char *)ast_config_AST_SPOOL_DIR, context, vmbox); if (!(vmdir = opendir(vmpath))) { ast_log(LOG_NOTICE, "Voice mailbox %s at %s does not exist\n", vmbox, vmpath); } else {