| Index: content/browser/renderer_host/media/audio_input_renderer_host.cc
|
| diff --git a/content/browser/renderer_host/media/audio_input_renderer_host.cc b/content/browser/renderer_host/media/audio_input_renderer_host.cc
|
| index 149d4b8b12fd64f9a3f6913d8f75ed91a9567f27..031f520c28bfac5f11429db94677fc8af4d5c6f0 100644
|
| --- a/content/browser/renderer_host/media/audio_input_renderer_host.cc
|
| +++ b/content/browser/renderer_host/media/audio_input_renderer_host.cc
|
| @@ -208,15 +208,15 @@ void AudioInputRendererHost::OnCreateStream(int stream_id,
|
|
|
| AudioParameters audio_params(params);
|
|
|
| - DCHECK_GT(audio_params.samples_per_packet, 0);
|
| - uint32 packet_size = audio_params.GetPacketSize();
|
| + DCHECK_GT(audio_params.frames_per_buffer(), 0);
|
| + uint32 buffer_size = audio_params.GetBytesPerBuffer();
|
|
|
| // Create a new AudioEntry structure.
|
| scoped_ptr<AudioEntry> entry(new AudioEntry());
|
|
|
| // Create the shared memory and share it with the renderer process
|
| // using a new SyncWriter object.
|
| - if (!entry->shared_memory.CreateAndMapAnonymous(packet_size)) {
|
| + if (!entry->shared_memory.CreateAndMapAnonymous(buffer_size)) {
|
| // If creation of shared memory failed then send an error message.
|
| SendErrorMessage(stream_id);
|
| return;
|
|
|