Fix misleading indentation.
There isn't actually a bug here, but we'd like to turn
-Wmisleading-indentation on.
My understanding is that -- despite this being in external/ -- we are
actually the upstream for sonivox anyway, hence the fix.
Test: treehugger
Change-Id: I61ac054c32525b8509baafd70840fbed0f1ab7c4
diff --git a/arm-wt-22k/lib_src/eas_mdls.c b/arm-wt-22k/lib_src/eas_mdls.c
index fac6987..6771261 100644
--- a/arm-wt-22k/lib_src/eas_mdls.c
+++ b/arm-wt-22k/lib_src/eas_mdls.c
@@ -1340,31 +1340,32 @@
if ((result = EAS_HWFileSeek(pDLSData->hwInstData, pDLSData->fileHandle, pos)) != EAS_SUCCESS)
return result;
- p = pSample;
+ p = pSample;
- while (size)
+ while (size)
+ {
+ /* read a small chunk of data and convert it */
+ count = (size < SAMPLE_CONVERT_CHUNK_SIZE ? size : SAMPLE_CONVERT_CHUNK_SIZE);
+ if ((result = EAS_HWReadFile(pDLSData->hwInstData, pDLSData->fileHandle, convBuf, count, &count)) != EAS_SUCCESS)
{
- /* read a small chunk of data and convert it */
- count = (size < SAMPLE_CONVERT_CHUNK_SIZE ? size : SAMPLE_CONVERT_CHUNK_SIZE);
- if ((result = EAS_HWReadFile(pDLSData->hwInstData, pDLSData->fileHandle, convBuf, count, &count)) != EAS_SUCCESS)
- {
- return result;
- }
- size -= count;
- if (pWsmp->bitsPerSample == 16)
- {
- memcpy(p, convBuf, count);
- p += count >> 1;
- }
- else
- {
- for(i=0; i<count; i++)
- {
- *p++ = (short)((convBuf[i] ^ 0x80) << 8);
- }
- }
-
+ return result;
}
+ size -= count;
+ if (pWsmp->bitsPerSample == 16)
+ {
+ memcpy(p, convBuf, count);
+ p += count >> 1;
+ }
+ else
+ {
+ for(i=0; i<count; i++)
+ {
+ *p++ = (short)((convBuf[i] ^ 0x80) << 8);
+ }
+ }
+
+ }
+
/* for looped samples, copy the last sample to the end */
if (pWsmp->loopLength)
{