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

Commit 244c73a2 authored by Andreas Huber's avatar Andreas Huber Committed by Android (Google) Code Review
Browse files

Merge "Make sure we can encode the size of the codec specific data in a single byte."

parents dc99cd65 5f995b0e
Loading
Loading
Loading
Loading
+3 −0
Original line number Diff line number Diff line
@@ -2194,6 +2194,9 @@ void MPEG4Writer::Track::writeTrackHeader(
                        CHECK(mCodecSpecificData);
                        CHECK(mCodecSpecificDataSize > 0);

                        // Make sure all sizes encode to a single byte.
                        CHECK(mCodecSpecificDataSize + 23 < 128);

                        mOwner->writeInt32(0);     // version=0, flags=0
                        mOwner->writeInt8(0x03);   // ES_DescrTag
                        mOwner->writeInt8(23 + mCodecSpecificDataSize);