Merged revisions 43893 via svnmerge from
authorJoshua Colp <jcolp@digium.com>
Thu, 28 Sep 2006 16:19:22 +0000 (16:19 +0000)
committerJoshua Colp <jcolp@digium.com>
Thu, 28 Sep 2006 16:19:22 +0000 (16:19 +0000)
https://origsvn.digium.com/svn/asterisk/branches/1.4

................
r43893 | file | 2006-09-28 12:17:36 -0400 (Thu, 28 Sep 2006) | 10 lines

Merged revisions 43891 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.2

........
r43891 | file | 2006-09-28 12:13:55 -0400 (Thu, 28 Sep 2006) | 2 lines

Stop the stream after waitstream returns so that our formats get restored. (issue #7370 reported by kryptolus)

........

................

git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@43894 65c4cc65-6c06-0410-ace0-fbb531ad65f3

apps/app_meetme.c

index d357f69..9659f3a 100644 (file)
@@ -1154,6 +1154,7 @@ static int conf_run(struct ast_channel *chan, struct ast_conference *conf, int c
                if (conf->users == 2) { 
                        if (!ast_streamfile(chan,"conf-onlyone",chan->language)) {
                                res = ast_waitstream(chan, AST_DIGIT_ANY);
+                               ast_stopstream(chan);
                                if (res > 0)
                                        keepplaying=0;
                                else if (res == -1)
@@ -1162,6 +1163,7 @@ static int conf_run(struct ast_channel *chan, struct ast_conference *conf, int c
                } else { 
                        if (!ast_streamfile(chan, "conf-thereare", chan->language)) {
                                res = ast_waitstream(chan, AST_DIGIT_ANY);
+                               ast_stopstream(chan);
                                if (res > 0)
                                        keepplaying=0;
                                else if (res == -1)
@@ -1176,6 +1178,7 @@ static int conf_run(struct ast_channel *chan, struct ast_conference *conf, int c
                        }
                        if (keepplaying && !ast_streamfile(chan, "conf-otherinparty", chan->language)) {
                                res = ast_waitstream(chan, AST_DIGIT_ANY);
+                               ast_stopstream(chan);
                                if (res > 0)
                                        keepplaying=0;
                                else if (res == -1) 
@@ -2358,8 +2361,10 @@ static int conf_exec(struct ast_channel *chan, void *data)
                                                                break;
                                                        } else {
                                                                /* Pin invalid */
-                                                               if (!ast_streamfile(chan, "conf-invalidpin", chan->language))
+                                                               if (!ast_streamfile(chan, "conf-invalidpin", chan->language)) {
                                                                        res = ast_waitstream(chan, AST_DIGIT_ANY);
+                                                                       ast_stopstream(chan);
+                                                               }
                                                                else {
                                                                        ast_log(LOG_WARNING, "Couldn't play invalid pin msg!\n");
                                                                        break;