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

Commit b35b873f authored by Linux Build Service Account's avatar Linux Build Service Account Committed by Gerrit - the friendly Code Review server
Browse files

Merge "rtsp: Limit subframe processing to available buffer range"

parents adbffe32 9c9830ab
Loading
Loading
Loading
Loading
+5 −0
Original line number Diff line number Diff line
@@ -419,6 +419,11 @@ sp<ABuffer> AMPEG4AudioAssembler::removeLATMFraming(const sp<ABuffer> &buffer) {
            CHECK_LE(offset + (mOtherDataLenBits / 8), buffer->size());
            offset += mOtherDataLenBits / 8;
        }

        if (i < mNumSubFrames && offset >= buffer->size()) {
            ALOGW("Skip subframes after %d, total %d", (int)i, (int)mNumSubFrames);
            break;
        }
    }

    if (offset < buffer->size()) {