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

Commit 0bfa3eee authored by Andy Hung's avatar Andy Hung
Browse files

MediaPlayer/MediaRecorder: Do not notify client of audioserver death

Handled internally within NuPlayer and MediaRecorder.

Bug: 28768023
Change-Id: I26d94332a4668bf7a8ad54a7b25e6f0a3a6fe48d
parent e35bcaa2
Loading
Loading
Loading
Loading
+0 −4
Original line number Diff line number Diff line
@@ -682,10 +682,6 @@ sp<MediaPlayerBase> MediaPlayerService::Client::setDataSource_pre(
    mCodecDeathListener = new ServiceDeathNotifier(binder, p, MEDIACODEC_PROCESS_DEATH);
    binder->linkToDeath(mCodecDeathListener);

    binder = sm->getService(String16("media.audio_flinger"));
    mAudioDeathListener = new ServiceDeathNotifier(binder, p, AUDIO_PROCESS_DEATH);
    binder->linkToDeath(mAudioDeathListener);

    if (!p->hardwareOutput()) {
        Mutex::Autolock l(mLock);
        mAudioOutput = new AudioOutput(mAudioSessionId, IPCThreadState::self()->getCallingUid(),
+1 −2
Original line number Diff line number Diff line
@@ -231,7 +231,7 @@ public:
        MEDIASERVER_PROCESS_DEATH = 0,
        MEDIAEXTRACTOR_PROCESS_DEATH = 1,
        MEDIACODEC_PROCESS_DEATH = 2,
        AUDIO_PROCESS_DEATH = 3,
        AUDIO_PROCESS_DEATH = 3,   // currently no need to track this
        CAMERA_PROCESS_DEATH = 4
    };

@@ -419,7 +419,6 @@ private:

        sp<IBinder::DeathRecipient> mExtractorDeathListener;
        sp<IBinder::DeathRecipient> mCodecDeathListener;
        sp<IBinder::DeathRecipient> mAudioDeathListener;
#if CALLBACK_ANTAGONIZER
                    Antagonizer*                mAntagonizer;
#endif
+0 −5
Original line number Diff line number Diff line
@@ -378,11 +378,6 @@ status_t MediaRecorderClient::setListener(const sp<IMediaRecorderClient>& listen
            MediaPlayerService::MEDIACODEC_PROCESS_DEATH);
    binder->linkToDeath(mCodecDeathListener);

    binder = sm->getService(String16("media.audio_flinger"));
    mAudioDeathListener = new ServiceDeathNotifier(binder, listener,
            MediaPlayerService::AUDIO_PROCESS_DEATH);
    binder->linkToDeath(mAudioDeathListener);

    return OK;
}

+0 −1
Original line number Diff line number Diff line
@@ -87,7 +87,6 @@ private:

    sp<IBinder::DeathRecipient> mCameraDeathListener;
    sp<IBinder::DeathRecipient> mCodecDeathListener;
    sp<IBinder::DeathRecipient> mAudioDeathListener;

    pid_t                  mPid;
    Mutex                  mLock;