Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit f96ebc66 authored by James Dong's avatar James Dong Committed by Android (Google) Code Review
Browse files

Merge "PV's mp3 decoder mistreated inputBufferCurrentLength in unit of bytes as in unit of bits"

parents 3fd91bae ebdc652a
Loading
Loading
Loading
Loading
+4 −2
Original line number Diff line number Diff line
@@ -122,8 +122,10 @@ ERROR_CODE pvmp3_decode_header(tmp3Bits *inputStream,

    /*
     * Verify that at least the header is complete
     * Note that SYNC_WORD_LNGTH is in unit of bits, but inputBufferCurrentLength
     * is in unit of bytes.
     */
    if (inputStream->inputBufferCurrentLength < (SYNC_WORD_LNGTH + 21))
    if (inputStream->inputBufferCurrentLength < ((SYNC_WORD_LNGTH + 21) >> 3))
    {
        return NO_ENOUGH_MAIN_DATA_ERROR;
    }