don't twiddle memory that doesn't belong to us (issue #5348)

git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@6727 65c4cc65-6c06-0410-ace0-fbb531ad65f3
This commit is contained in:
Kevin P. Fleming
2005-10-05 00:28:04 +00:00
parent 130bf3b9e0
commit 17b668e180

View File

@@ -389,7 +389,7 @@ static void adjust_volume(struct ast_frame *f, int vol)
int count;
short *fdata = f->data;
for (count = 0; count < f->datalen; count++) {
for (count = 0; count < (f->datalen / sizeof(*fdata)); count++) {
if (vol > 0) {
fdata[count] *= abs(vol);
} else if (vol < 0) {