HonamiCyan/android_frameworks_av — pull request #1 by MightyBear007 (2014-05-04 08:11:33+00:00)
Title: audio: Fixed mBytesRemaining when partial buffers are sent

- When AudioFlinger writes partial buffers to HAL,
write() on HAl returns period_size if bytes written
are less than period_size. This is causing
mBytesRemaining to be negative

- Fix is to check the return value of write() and
set mBytesRemaining and mBytesWritten correctly

Change-Id: Ibd3cb138c0d4669e9e17c22f6b2c80804c6499a5
CRs-fixed: 611119