mirror of
https://github.com/asterisk/asterisk.git
synced 2025-11-19 00:00:09 +00:00
voicemail beep shouldn't be played till we get next message number (bug #2594)
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/v1-0@3942 65c4cc65-6c06-0410-ace0-fbb531ad65f3
This commit is contained in:
@@ -1417,12 +1417,6 @@ static int leave_voicemail(struct ast_channel *chan, char *ext, int silent, int
|
|||||||
free_user(vmu);
|
free_user(vmu);
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
if (res >= 0) {
|
|
||||||
/* Unless we're *really* silent, try to send the beep */
|
|
||||||
res = ast_streamfile(chan, "beep", chan->language);
|
|
||||||
if (!res)
|
|
||||||
res = ast_waitstream(chan, "");
|
|
||||||
}
|
|
||||||
if (res < 0) {
|
if (res < 0) {
|
||||||
free_user(vmu);
|
free_user(vmu);
|
||||||
return -1;
|
return -1;
|
||||||
@@ -1437,6 +1431,12 @@ static int leave_voicemail(struct ast_channel *chan, char *ext, int silent, int
|
|||||||
break;
|
break;
|
||||||
msgnum++;
|
msgnum++;
|
||||||
} while(msgnum < MAXMSG);
|
} while(msgnum < MAXMSG);
|
||||||
|
if (res >= 0) {
|
||||||
|
/* Unless we're *really* silent, try to send the beep */
|
||||||
|
res = ast_streamfile(chan, "beep", chan->language);
|
||||||
|
if (!res)
|
||||||
|
res = ast_waitstream(chan, "");
|
||||||
|
}
|
||||||
if (msgnum < MAXMSG) {
|
if (msgnum < MAXMSG) {
|
||||||
/* Store information */
|
/* Store information */
|
||||||
snprintf(txtfile, sizeof(txtfile), "%s.txt", fn);
|
snprintf(txtfile, sizeof(txtfile), "%s.txt", fn);
|
||||||
|
|||||||
Reference in New Issue
Block a user