Index: webrtc/modules/audio_coding/main/acm2/acm_resampler.cc |
diff --git a/webrtc/modules/audio_coding/main/acm2/acm_resampler.cc b/webrtc/modules/audio_coding/main/acm2/acm_resampler.cc |
index 97d87b1b3a4b357939d27b089f94c70598728a26..2650725331b94e5db5e110836704d11082657ec6 100644 |
--- a/webrtc/modules/audio_coding/main/acm2/acm_resampler.cc |
+++ b/webrtc/modules/audio_coding/main/acm2/acm_resampler.cc |
@@ -29,9 +29,9 @@ int ACMResampler::Resample10Msec(const int16_t* in_audio, |
int in_freq_hz, |
int out_freq_hz, |
int num_audio_channels, |
- int out_capacity_samples, |
+ size_t out_capacity_samples, |
int16_t* out_audio) { |
- int in_length = in_freq_hz * num_audio_channels / 100; |
+ size_t in_length = static_cast<size_t>(in_freq_hz * num_audio_channels / 100); |
int out_length = out_freq_hz * num_audio_channels / 100; |
if (in_freq_hz == out_freq_hz) { |
if (out_capacity_samples < in_length) { |
@@ -39,7 +39,7 @@ int ACMResampler::Resample10Msec(const int16_t* in_audio, |
return -1; |
} |
memcpy(out_audio, in_audio, in_length * sizeof(int16_t)); |
- return in_length / num_audio_channels; |
+ return static_cast<int>(in_length / num_audio_channels); |
} |
if (resampler_.InitializeIfNeeded(in_freq_hz, out_freq_hz, |