avoid segfault when playing a 48k wav as a transfer ringback to an 8k ulaw channel

git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@11101 d0543943-73ff-0310-b7d9-9358b9ac24b2
This commit is contained in:
Brian West 2009-01-09 03:28:52 +00:00
parent da034c4fbb
commit df2913511c
1 changed files with 1 additions and 1 deletions

View File

@ -165,7 +165,7 @@ SWITCH_DECLARE(switch_status_t) switch_core_file_read(switch_file_handle_t *fh,
switch_assert(fh->buffer); switch_assert(fh->buffer);
} }
if (!fh->dbuf) { if (!fh->dbuf) {
fh->dbuflen = fh->resampler->to_len * 8; fh->dbuflen = fh->resampler->to_len * 10;
fh->dbuf = switch_core_alloc(fh->memory_pool, fh->dbuflen); fh->dbuf = switch_core_alloc(fh->memory_pool, fh->dbuflen);
} }
switch_assert(fh->resampler->to_len <= fh->dbuflen); switch_assert(fh->resampler->to_len <= fh->dbuflen);