mirror of
https://github.com/signalwire/freeswitch.git
synced 2025-06-02 19:40:08 +00:00
FS-5229 --resolve oops, i missed the part that its subsequent calls to displace
This commit is contained in:
parent
c510a81177
commit
b4e21fd3f6
@ -844,8 +844,9 @@ static switch_bool_t write_displace_callback(switch_media_bug_t *bug, void *user
|
|||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
st = switch_core_file_read(&dh->fh, rframe->data, &len);
|
st = switch_core_file_read(&dh->fh, rframe->data, &len);
|
||||||
rframe->samples = (uint32_t) len;
|
if (len < rframe->samples) {
|
||||||
rframe->datalen = rframe->samples * 2;
|
memset(rframe->data, 0, rframe->datalen - len * 2);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (st != SWITCH_STATUS_SUCCESS || len == 0) {
|
if (st != SWITCH_STATUS_SUCCESS || len == 0) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user