aboutsummaryrefslogtreecommitdiffstats
path: root/addons
diff options
context:
space:
mode:
authorrussell <russell@f38db490-d61c-443f-a65b-d21fe96a405b>2009-09-08 18:06:57 +0000
committerrussell <russell@f38db490-d61c-443f-a65b-d21fe96a405b>2009-09-08 18:06:57 +0000
commitaf9544cd4c529cc7ad75e5616937029cae749f80 (patch)
tree74cc355b03deddd3a1778d47fd58c7c7d8186de8 /addons
parenta6dbb7907687d683cbe991a85b2e08dde3c6595e (diff)
Fix audio problems with format_mp3.
This problem was introduced when the AST_FRIENDLY_OFFSET patch was merged. I'm surprised that nobody noticed any trouble when testing that patch, but this fixes the code that fills in the buffer to start filling in after the offset portion of the buffer. (closes issue #15850) Reported by: 99gixxer Patches: issue15850.diff1.txt uploaded by russell (license 2) Tested by: 99gixxer git-svn-id: http://svn.digium.com/svn/asterisk/trunk@217113 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'addons')
-rw-r--r--addons/format_mp3.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/addons/format_mp3.c b/addons/format_mp3.c
index ae6c1a68b..81d2a0d71 100644
--- a/addons/format_mp3.c
+++ b/addons/format_mp3.c
@@ -200,7 +200,7 @@ static struct ast_frame *mp3_read(struct ast_filestream *s, int *whennext)
if(p->dbuflen) {
for(p->buflen=0; p->buflen < MP3_BUFLEN && p->buflen < p->dbuflen; p->buflen++) {
- s->buf[p->buflen] = p->dbuf[p->buflen+p->dbufoffset];
+ s->buf[p->buflen + AST_FRIENDLY_OFFSET] = p->dbuf[p->buflen+p->dbufoffset];
p->sbufoffset++;
}
p->dbufoffset += p->buflen;
@@ -211,7 +211,7 @@ static struct ast_frame *mp3_read(struct ast_filestream *s, int *whennext)
return NULL;
for(save = p->buflen; p->buflen < MP3_BUFLEN; p->buflen++) {
- s->buf[p->buflen] = p->dbuf[(p->buflen-save)+p->dbufoffset];
+ s->buf[p->buflen + AST_FRIENDLY_OFFSET] = p->dbuf[(p->buflen-save)+p->dbufoffset];
p->sbufoffset++;
}
p->dbufoffset += (MP3_BUFLEN - save);