Merged revisions 33513 via svnmerge from
authorRussell Bryant <russell@russellbryant.com>
Sun, 11 Jun 2006 20:46:05 +0000 (20:46 +0000)
committerRussell Bryant <russell@russellbryant.com>
Sun, 11 Jun 2006 20:46:05 +0000 (20:46 +0000)
https://origsvn.digium.com/svn/asterisk/branches/1.2

........
r33513 | russell | 2006-06-11 16:45:06 -0400 (Sun, 11 Jun 2006) | 2 lines

fix a couple places that would leak a frame

........

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

apps/app_festival.c

index e7cbd47..6a67ad5 100644 (file)
@@ -238,11 +238,13 @@ static int send_waveform_to_channel(struct ast_channel *chan, char *waveform, in
                                        myf.f.data = myf.frdata;
                                        if (ast_write(chan, &myf.f) < 0) {
                                                res = -1;
+                                               ast_frfree(f);
                                                break;
                                        }
                                        if (res < needed) { /* last frame */
                                                ast_log(LOG_DEBUG, "Last frame\n");
                                                res=0;
+                                               ast_frfree(f);
                                                break;
                                        }
                                } else {