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

Commit 7d39a1b2 authored by Andreas Huber's avatar Andreas Huber Committed by Android Git Automerger
Browse files

am 215aeda9: am 2cb138db: Merge "After failing to create an AudioTrack, only...

am 215aeda9: am 2cb138db: Merge "After failing to create an AudioTrack, only stop the source if we were the ones starting it." into kraken
parents b8fbe1f2 215aeda9
Loading
Loading
Loading
Loading
+6 −2
Original line number Diff line number Diff line
@@ -87,7 +87,9 @@ status_t AudioPlayer::start(bool sourceAlreadyStarted) {
                DEFAULT_AUDIOSINK_BUFFERCOUNT,
                &AudioPlayer::AudioSinkCallback, this);
        if (err != OK) {
            if (!sourceAlreadyStarted) {
                mSource->stop();
            }

            return err;
        }
@@ -108,7 +110,9 @@ status_t AudioPlayer::start(bool sourceAlreadyStarted) {
            delete mAudioTrack;
            mAudioTrack = NULL;

            if (!sourceAlreadyStarted) {
                mSource->stop();
            }

            return err;
        }