aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authortilghman <tilghman@f38db490-d61c-443f-a65b-d21fe96a405b>2007-01-07 21:44:52 +0000
committertilghman <tilghman@f38db490-d61c-443f-a65b-d21fe96a405b>2007-01-07 21:44:52 +0000
commit2fec763382a82f8e8002199247cebf3d87fcf452 (patch)
tree17f4465e285f16e096057510cfe9cbf257b154dd
parentb28e20fc42a0cd0f3fb6c48fa9cb3c0eb4e9cd18 (diff)
Merged revisions 49833 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.2 ........ r49833 | tilghman | 2007-01-07 15:43:10 -0600 (Sun, 07 Jan 2007) | 2 lines If openstream fails, then we crash (Issue 8564) ........ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@49834 f38db490-d61c-443f-a65b-d21fe96a405b
-rw-r--r--apps/app_dictate.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/apps/app_dictate.c b/apps/app_dictate.c
index 0c46118e4..16a79b3a5 100644
--- a/apps/app_dictate.c
+++ b/apps/app_dictate.c
@@ -267,7 +267,8 @@ static int dictate_exec(struct ast_channel *chan, void *data)
if (lastop != DFLAG_PLAY) {
lastop = DFLAG_PLAY;
ast_closestream(fs);
- fs = ast_openstream(chan, path, chan->language);
+ if (!(fs = ast_openstream(chan, path, chan->language)))
+ break;
ast_seekstream(fs, samples, SEEK_SET);
chan->stream = NULL;
}