summaryrefslogtreecommitdiff
path: root/codecs/codec_speex.c
diff options
context:
space:
mode:
authorJason Parker <jparker@digium.com>2008-05-22 17:10:53 +0000
committerJason Parker <jparker@digium.com>2008-05-22 17:10:53 +0000
commitf7eb823a7a4551139abd677a2024705012d035c6 (patch)
tree9a258decae4f074f9e9a7bfe05180c78af99aca4 /codecs/codec_speex.c
parent5ceec8b05232152eb8c3a6dab74cc39baa7abe8e (diff)
Fix a few places where frame data was used directly.
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@117828 65c4cc65-6c06-0410-ace0-fbb531ad65f3
Diffstat (limited to 'codecs/codec_speex.c')
-rw-r--r--codecs/codec_speex.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/codecs/codec_speex.c b/codecs/codec_speex.c
index 494693182..b9f879535 100644
--- a/codecs/codec_speex.c
+++ b/codecs/codec_speex.c
@@ -165,7 +165,7 @@ static struct ast_frame *lintospeex_sample(void)
f.mallocd = 0;
f.offset = 0;
f.src = __PRETTY_FUNCTION__;
- f.data = slin_speex_ex;
+ f.data.ptr = slin_speex_ex;
return &f;
}
@@ -180,7 +180,7 @@ static struct ast_frame *speextolin_sample(void)
f.mallocd = 0;
f.offset = 0;
f.src = __PRETTY_FUNCTION__;
- f.data = speex_slin_ex;
+ f.data.ptr = speex_slin_ex;
return &f;
}
@@ -220,7 +220,7 @@ static int speextolin_framein(struct ast_trans_pvt *pvt, struct ast_frame *f)
}
/* Read in bits */
- speex_bits_read_from(&tmp->bits, f->data, f->datalen);
+ speex_bits_read_from(&tmp->bits, f->data.ptr, f->datalen);
for (;;) {
#ifdef _SPEEX_TYPES_H
res = speex_decode_int(tmp->speex, &tmp->bits, fout);
@@ -249,7 +249,7 @@ static int lintospeex_framein(struct ast_trans_pvt *pvt, struct ast_frame *f)
/* XXX We should look at how old the rest of our stream is, and if it
is too old, then we should overwrite it entirely, otherwise we can
get artifacts of earlier talk that do not belong */
- memcpy(tmp->buf + pvt->samples, f->data, f->datalen);
+ memcpy(tmp->buf + pvt->samples, f->data.ptr, f->datalen);
pvt->samples += f->samples;
return 0;
}