From 08132bdf001990dcce7165e0ef1d894313748f8d Mon Sep 17 00:00:00 2001 From: Tilghman Lesher <tilghman@meg.abyt.es> Date: Sat, 18 Feb 2006 00:32:10 +0000 Subject: [PATCH] Merged revisions 10409 via svnmerge from https://origsvn.digium.com/svn/asterisk/branches/1.2 ........ r10409 | tilghman | 2006-02-17 18:17:09 -0600 (Fri, 17 Feb 2006) | 2 lines Bug 6529 - memory leak in ast_play_and_prepend ........ git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@10410 65c4cc65-6c06-0410-ace0-fbb531ad65f3 --- app.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/app.c b/app.c index 1d85fea321..51a668b538 100644 --- a/app.c +++ b/app.c @@ -852,6 +852,7 @@ int ast_play_and_prepend(struct ast_channel *chan, char *playfile, char *recordf res = ast_set_read_format(chan, AST_FORMAT_SLINEAR); if (res < 0) { ast_log(LOG_WARNING, "Unable to set to linear mode, giving up\n"); + ast_dsp_free(sildet); return -1; } } @@ -956,6 +957,7 @@ int ast_play_and_prepend(struct ast_channel *chan, char *playfile, char *recordf } else { ast_log(LOG_WARNING, "Error creating writestream '%s', format '%s'\n", prependfile, sfmt[x]); } + ast_dsp_free(sildet); *duration = end - start; #if 0 if (outmsg > 1) { -- GitLab