b.delay_ns = 0;
struct pcm_device *pcm_device;
+ if (list_empty(&in->pcm_dev_list)) {
+ ALOGW("%s: pcm device list empty", __func__);
+ return b.delay_ns;
+ }
+
pcm_device = node_to_item(list_head(&in->pcm_dev_list),
struct pcm_device, stream_list_node);
struct pcm_device *pcm_device;
int ret = -ENOSYS;
+ if (list_empty(&in->pcm_dev_list)) {
+ ALOGW("%s: pcm device list empty", __func__);
+ return -ENODEV;
+ }
+
pcm_device = node_to_item(list_head(&in->pcm_dev_list),
struct pcm_device, stream_list_node);