Fix Windows warnings

This commit is contained in:
badaix 2020-04-10 13:27:08 +02:00
parent ade0ee7be3
commit e5047f1aff
12 changed files with 167 additions and 165 deletions

View file

@ -50,8 +50,8 @@ bool OpusDecoder::decode(msg::PcmChunk* chunk)
{
int frame_size = 0;
while ((frame_size = opus_decode(dec_, (unsigned char*)chunk->payload, chunk->payloadSize, pcm_.data(), pcm_.size() / sample_format_.channels(), 0)) ==
OPUS_BUFFER_TOO_SMALL)
while ((frame_size = opus_decode(dec_, (unsigned char*)chunk->payload, chunk->payloadSize, pcm_.data(),
static_cast<int>(pcm_.size()) / sample_format_.channels(), 0)) == OPUS_BUFFER_TOO_SMALL)
{
if (pcm_.size() < const_max_frame_size * sample_format_.channels())
{