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

Commit 0147f95f authored by Marco Nelissen's avatar Marco Nelissen
Browse files

Fix media extractor abort

Bug: 111764444
Test: manual
Change-Id: Iae6238c26ef8c0971c65e4403b933970a562221a
parent 19283e9d
Loading
Loading
Loading
Loading
+5 −1
Original line number Diff line number Diff line
@@ -5231,9 +5231,13 @@ status_t MPEG4Source::fragmentedRead(
    uint32_t cts = 0;
    bool isSyncSample = false;
    bool newBuffer = false;
    if (mBuffer == NULL) {
    if (mBuffer == NULL || mCurrentSampleIndex >= mCurrentSamples.size()) {
        newBuffer = true;

        if (mBuffer != NULL) {
            mBuffer->release();
            mBuffer = NULL;
        }
        if (mCurrentSampleIndex >= mCurrentSamples.size()) {
            // move to next fragment if there is one
            if (mNextMoofOffset <= mCurrentMoofOffset) {