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

Commit 2f67f41d authored by Harish Mahendrakar (xWF)'s avatar Harish Mahendrakar (xWF)
Browse files

C2SoftMp3Dec: Fix potential null reference in onStop()

Bug: 364989775
Test: Treehugger

Change-Id: Id3e611817c2308ea7afb1fa9a1a35532220b52db
parent 30ce127f
Loading
Loading
Loading
Loading
+3 −1
Original line number Original line Diff line number Diff line
@@ -114,7 +114,9 @@ c2_status_t C2SoftMP3::onInit() {
c2_status_t C2SoftMP3::onStop() {
c2_status_t C2SoftMP3::onStop() {
    // Make sure that the next buffer output does not still
    // Make sure that the next buffer output does not still
    // depend on fragments from the last one decoded.
    // depend on fragments from the last one decoded.
    if (mDecoderBuf) {
        pvmp3_InitDecoder(mConfig, mDecoderBuf);
        pvmp3_InitDecoder(mConfig, mDecoderBuf);
    }
    mSignalledError = false;
    mSignalledError = false;
    mIsFirst = true;
    mIsFirst = true;
    mSignalledOutputEos = false;
    mSignalledOutputEos = false;