From 5567aaf4818007cd8e77329683a91c0f5d7a8837 Mon Sep 17 00:00:00 2001 From: Andy Hung Date: Thu, 17 Jul 2014 14:00:07 -0700 Subject: Fix initial audio glitch on startup Also happens when restarting AudioFlinger. Bug: 16322824 Change-Id: I382b20174cb0639e04316130141f2094d7dd0cb3 --- services/audioflinger/Threads.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'services/audioflinger') diff --git a/services/audioflinger/Threads.cpp b/services/audioflinger/Threads.cpp index 0f01b02..a396aaf 100755 --- a/services/audioflinger/Threads.cpp +++ b/services/audioflinger/Threads.cpp @@ -3643,7 +3643,7 @@ track_is_ready: ; memset(mEffectBuffer, 0, mEffectBufferSize); } // FIXME as a performance optimization, should remember previous zero status - memset(mSinkBuffer, 0, mNormalFrameCount * mChannelCount * sizeof(int16_t)); + memset(mSinkBuffer, 0, mNormalFrameCount * mFrameSize); } // if any fast tracks, then status is ready -- cgit v1.1