Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(286)

Unified Diff: Source/WebCore/platform/audio/HRTFPanner.cpp

Issue 8231033: Merge 97214 - Heap buffer overflow in Webaudio FFTFrame::doFFT (Closed) Base URL: http://svn.webkit.org/repository/webkit/branches/chromium/874/
Patch Set: Created 9 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « Source/WebCore/platform/audio/HRTFKernel.cpp ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/WebCore/platform/audio/HRTFPanner.cpp
===================================================================
--- Source/WebCore/platform/audio/HRTFPanner.cpp (revision 97216)
+++ Source/WebCore/platform/audio/HRTFPanner.cpp (working copy)
@@ -64,9 +64,9 @@
{
// The HRTF impulse responses (loaded as audio resources) are 512 sample-frames @44.1KHz.
// Currently, we truncate the impulse responses to half this size, but an FFT-size of twice impulse response size is needed (for convolution).
- // So for sample rates around 44.1KHz an FFT size of 512 is good. We double that size for higher sample rates.
+ // So for sample rates around 44.1KHz an FFT size of 512 is good. We double the FFT-size only for sample rates at least double this.
ASSERT(sampleRate >= 44100 && sampleRate <= 96000.0);
- return (sampleRate <= 48000.0) ? 512 : 1024;
+ return (sampleRate < 88200.0) ? 512 : 1024;
}
void HRTFPanner::reset()
« no previous file with comments | « Source/WebCore/platform/audio/HRTFKernel.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698