OSDN Git Service

audio: allow audio port cache update even when audio patches contain invalidated...
authorWonsik Kim <wonsik@google.com>
Fri, 30 Jan 2015 08:48:51 +0000 (17:48 +0900)
committerWonsik Kim <wonsik@google.com>
Sat, 31 Jan 2015 01:51:28 +0000 (01:51 +0000)
commitb561ccedd89f92b249c06522e960b135a02107d8
treea863431c31eb0c7db140139e1021523b6f703ab4
parent3548de60735a79d3e7087c26ae491a7f38da5b4d
audio: allow audio port cache update even when audio patches contain invalidated sources/sinks

When an audio device disconnects from Android, custom audio patches
containing the device become invalidated.
AudioManager::updateAudioPortCache() used to fail in that case, but
it causes onAudioPortListUpdated() event never gets called so that
the creator of the custom audio patch cannot update it. Let
updateAudioPortCached() succeed even in the case so that the entity
that created the audio patch can get notified.

Bug: 18909299
Change-Id: If4f6ed73f69213d792117fb42aec103ae2e50b79
media/java/android/media/AudioManager.java