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

Commit 45e93804 authored by Steve Kondik's avatar Steve Kondik
Browse files

stagefright: Revert patches which should not have carried over

 * These patches cause problems on L, revert them.

Revert "Disconnect the mediaplayer when reset"

This reverts commit 9ab0b00d.

Revert "Remove potential cause of underrun."

This reverts commit a6027112.

Change-Id: I1ee0a447cc5820afd4c068170d6d04b50e45a36d
parent 97d303e4
Loading
Loading
Loading
Loading
+10 −0
Original line number Original line Diff line number Diff line
@@ -1943,6 +1943,16 @@ nsecs_t AudioTrack::processAudioBuffer()
            return NS_NEVER;
            return NS_NEVER;
        }
        }


        if (mRetryOnPartialBuffer && !isOffloaded()) {
            mRetryOnPartialBuffer = false;
            if (avail < mRemainingFrames) {
                int64_t myns = ((mRemainingFrames - avail) * 1100000000LL) / sampleRate;
                if (ns < 0 || myns < ns) {
                    ns = myns;
                }
                return ns;
            }
        }


        // Divide buffer size by 2 to take into account the expansion
        // Divide buffer size by 2 to take into account the expansion
        // due to 8 to 16 bit conversion: the callback must fill only half
        // due to 8 to 16 bit conversion: the callback must fill only half
+0 −1
Original line number Original line Diff line number Diff line
@@ -519,7 +519,6 @@ status_t MediaPlayer::reset_l()
        }
        }
        // setDataSource has to be called again to create a
        // setDataSource has to be called again to create a
        // new mediaplayer.
        // new mediaplayer.
        mPlayer->disconnect();
        mPlayer = 0;
        mPlayer = 0;
        return ret;
        return ret;
    }
    }