]> git.ipfire.org Git - thirdparty/asterisk.git/commitdiff
automerge commit
authorAutomerge script <automerge@asterisk.org>
Sun, 11 Jun 2006 21:04:25 +0000 (21:04 +0000)
committerAutomerge script <automerge@asterisk.org>
Sun, 11 Jun 2006 21:04:25 +0000 (21:04 +0000)
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.2-netsec@33544 65c4cc65-6c06-0410-ace0-fbb531ad65f3

apps/app_alarmreceiver.c
apps/app_festival.c
apps/app_ices.c

index 95abe1439eba796c2207ebc1da186bbfd274c828..ae564d841dadccafcdd59104e13d170f7cde3603 100644 (file)
@@ -215,6 +215,7 @@ static int send_tone_burst(struct ast_channel *chan, float freq, int duration, i
 
                        i += wf.datalen / 8;
                        if (i > duration) {
+                               ast_frfree(f);
                                break;
                        }
                        if (ast_write(chan, &wf)){
@@ -222,6 +223,7 @@ static int send_tone_burst(struct ast_channel *chan, float freq, int duration, i
                                        ast_verbose(VERBOSE_PREFIX_4 "AlarmReceiver: Failed to write frame on %s\n", chan->name);
                                ast_log(LOG_WARNING, "AlarmReceiver Failed to write frame on %s\n",chan->name);
                                res = -1;
+                               ast_frfree(f);
                                break;
                        }
                }
index de1830fd2b9fb01f885859383ee9ed2d3ed580b2..3906d604aafa6a065e744bb08d4d4d7cf8aedd71 100644 (file)
@@ -234,11 +234,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 {
index 85f4159ec486a760722ec6a8b7b4ea8574610ff7..b6b5ad3f7634cda668e6d1210a46dbce9a2483c3 100644 (file)
@@ -175,6 +175,7 @@ static int ices_exec(struct ast_channel *chan, void *data)
                                        if (errno != EAGAIN) {
                                                ast_log(LOG_WARNING, "Write failed to pipe: %s\n", strerror(errno));
                                                res = -1;
+                                               ast_frfree(f);
                                                break;
                                        }
                                }