audio: avoid latent media server crash during device is booting

Sometimes media server is killed by alsa_ucm during device is booting.
A alsa_ucm gets a index of "use case device" from get_use_case_index()
But, get_use_case_index() function can be returned a wrong value
(dev_index = -22 used index of dev_list[] array) at booting time.
This patch avoids latent media server crash causing abnormal value
as using index of dev_list[] array.

Change-Id: I961465f99b994d3ab1b26ee74d6d0978159960f4
1 file changed
tree: ea8af5f3a829e162bf67cf00be6fb567a66b136c
  1. alsa_sound/
  2. libalsa-intf/