diff options
author | tilghman <tilghman@f38db490-d61c-443f-a65b-d21fe96a405b> | 2007-06-26 12:25:58 +0000 |
---|---|---|
committer | tilghman <tilghman@f38db490-d61c-443f-a65b-d21fe96a405b> | 2007-06-26 12:25:58 +0000 |
commit | d6a4a47e6168602dd35af98246187a7a4d88264d (patch) | |
tree | 8eac8c7dc535182159517be5e2909269c92b51d1 /apps | |
parent | 86943460c3894b458ae56214f357132c076b76a4 (diff) |
Issue 10062 - Trying to move a message without selecting one first results in memory corruption
git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.2@71750 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'apps')
-rw-r--r-- | apps/app_voicemail.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/apps/app_voicemail.c b/apps/app_voicemail.c index e4dcce86f..98128957a 100644 --- a/apps/app_voicemail.c +++ b/apps/app_voicemail.c @@ -5478,6 +5478,11 @@ static int vm_execmain(struct ast_channel *chan, void *data) cmd = ast_play_and_wait(chan, "vm-nomore"); break; case '9': + if (vms.curmsg < 0 || vms.curmsg > vms.lastmsg) { + /* No message selected */ + cmd = 0; + break; + } if (useadsi) adsi_folders(chan, 1, "Save to folder..."); cmd = get_folder2(chan, "vm-savefolder", 1); |