Skip mAudioManager callback if it is null
When HearingAidService (in thread A) calls `Stop`, it unregisters callback for `onAudioDevicesRemoved` and sets `mAudioManager` to null. The `onAudioDevicesRemoved` callback goes to AudioManager's message queue (in thread B), and when AudioManager starts to process it, it finds `mAudioManager` is null, and crashes. Bug: 277851145 Change-Id: I685015efb1d5412479875580b82cfefa3611263a Test: atest avatar
Loading
Please register or sign in to comment