summaryrefslogtreecommitdiff
path: root/codecs
diff options
context:
space:
mode:
authorRussell Bryant <russell@russellbryant.com>2009-10-21 03:09:04 +0000
committerRussell Bryant <russell@russellbryant.com>2009-10-21 03:09:04 +0000
commitcd10bd931a7f54a516255adc25cd5b6ab2f7a75a (patch)
tree583949f7994c4051ee5d88cca57247c7c23d99e5 /codecs
parentc5b8e9af7c82867c8d5f8b0a2a2dbb28ddbf27d4 (diff)
Merged revisions 224931 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r224931 | russell | 2009-10-20 21:59:54 -0500 (Tue, 20 Oct 2009) | 5 lines Isolate frames returned from a DSP instance or codec translator. The reasoning for these changes are the same as what I wrote in the commit message for rev 222878. ........ git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@224932 65c4cc65-6c06-0410-ace0-fbb531ad65f3
Diffstat (limited to 'codecs')
-rw-r--r--codecs/codec_dahdi.c12
1 files changed, 4 insertions, 8 deletions
diff --git a/codecs/codec_dahdi.c b/codecs/codec_dahdi.c
index 4790aec96..eada4c2fd 100644
--- a/codecs/codec_dahdi.c
+++ b/codecs/codec_dahdi.c
@@ -235,10 +235,9 @@ static struct ast_frame *dahdi_encoder_frameout(struct ast_trans_pvt *pvt)
pvt->f.offset = 0;
pvt->f.datalen = 0;
pvt->f.mallocd = 0;
- ast_set_flag(&pvt->f, AST_FRFLAG_FROM_TRANSLATOR);
pvt->samples = 0;
- return &pvt->f;
+ return ast_frisolate(&pvt->f);
} else if (1 == dahdip->fake) {
dahdip->fake = 0;
@@ -263,11 +262,10 @@ static struct ast_frame *dahdi_encoder_frameout(struct ast_trans_pvt *pvt)
pvt->f.offset = AST_FRIENDLY_OFFSET;
pvt->f.src = pvt->t->name;
pvt->f.data.ptr = pvt->outbuf.c;
- ast_set_flag(&pvt->f, AST_FRFLAG_FROM_TRANSLATOR);
pvt->samples = 0;
pvt->datalen = 0;
- return &pvt->f;
+ return ast_frisolate(&pvt->f);
}
/* Shouldn't get here... */
@@ -310,9 +308,8 @@ static struct ast_frame *dahdi_decoder_frameout(struct ast_trans_pvt *pvt)
pvt->f.offset = 0;
pvt->f.datalen = 0;
pvt->f.mallocd = 0;
- ast_set_flag(&pvt->f, AST_FRFLAG_FROM_TRANSLATOR);
pvt->samples = 0;
- return &pvt->f;
+ return ast_frisolate(&pvt->f);
} else if (1 == dahdip->fake) {
pvt->samples = 0;
dahdip->fake = 0;
@@ -349,10 +346,9 @@ static struct ast_frame *dahdi_decoder_frameout(struct ast_trans_pvt *pvt)
pvt->f.src = pvt->t->name;
pvt->f.data.ptr = pvt->outbuf.c;
pvt->f.samples = dahdip->required_samples;
- ast_set_flag(&pvt->f, AST_FRFLAG_FROM_TRANSLATOR);
pvt->samples = 0;
- return &pvt->f;
+ return ast_frisolate(&pvt->f);
}
/* Shouldn't get here... */