When an element is marked as not readble, do not try to read it and then
complain about the error, but just ignore it.
Signed-off-by: Clemens Ladisch <clemens@ladisch.de>
break;
}
if (level & LEVEL_BASIC) {
+ if (!snd_ctl_elem_info_is_readable(info))
+ goto __skip_read;
if ((err = snd_hctl_elem_read(elem, control)) < 0) {
error("Control %s element read error: %s\n", card, snd_strerror(err));
return err;
}
}
printf("\n");
+ __skip_read:
if (!snd_ctl_elem_info_is_tlv_readable(info))
goto __skip_tlv;
tlv = malloc(4096);