aboutsummaryrefslogtreecommitdiffstats
path: root/res
diff options
context:
space:
mode:
authorrussell <russell@f38db490-d61c-443f-a65b-d21fe96a405b>2009-05-26 18:25:47 +0000
committerrussell <russell@f38db490-d61c-443f-a65b-d21fe96a405b>2009-05-26 18:25:47 +0000
commit2a2f0d5add4b075cfe8c82b531091ce332eccaaa (patch)
tree09643c64fac082e18a42f1199466c94be14874d7 /res
parent8fb224479e3c765a15cd41e624e2e7a1ae5910d9 (diff)
Merged revisions 196843 via svnmerge from
https://origsvn.digium.com/svn/asterisk/trunk ................ r196843 | russell | 2009-05-26 13:20:57 -0500 (Tue, 26 May 2009) | 16 lines Merged revisions 196826 via svnmerge from https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r196826 | russell | 2009-05-26 13:14:36 -0500 (Tue, 26 May 2009) | 9 lines Resolve a file handle leak. The frames here should have always been freed. However, out of luck, there was never any memory leaked. However, after file streams became reference counted, this code would leak the file stream for the file being read. (closes issue #15181) Reported by: jkroon ........ ................ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.0@196865 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'res')
-rw-r--r--res/res_convert.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/res/res_convert.c b/res/res_convert.c
index 0b4d664ff..264089c7f 100644
--- a/res/res_convert.c
+++ b/res/res_convert.c
@@ -117,9 +117,11 @@ static char *handle_cli_file_convert(struct ast_cli_entry *e, int cmd, struct as
while ((f = ast_readframe(fs_in))) {
if (ast_writestream(fs_out, f)) {
+ ast_frfree(f);
ast_cli(a->fd, "Failed to convert %s.%s to %s.%s!\n", name_in, ext_in, name_out, ext_out);
goto fail_out;
}
+ ast_frfree(f);
}
cost = ast_tvdiff_ms(ast_tvnow(), start);