|
@@ -889,7 +889,7 @@ static int snd_ctl_elem_read(struct snd_card *card,
|
|
|
|
|
|
index_offset = snd_ctl_get_ioff(kctl, &control->id);
|
|
index_offset = snd_ctl_get_ioff(kctl, &control->id);
|
|
vd = &kctl->vd[index_offset];
|
|
vd = &kctl->vd[index_offset];
|
|
- if (!(vd->access & SNDRV_CTL_ELEM_ACCESS_READ) && kctl->get == NULL)
|
|
|
|
|
|
+ if (!(vd->access & SNDRV_CTL_ELEM_ACCESS_READ) || kctl->get == NULL)
|
|
return -EPERM;
|
|
return -EPERM;
|
|
|
|
|
|
snd_ctl_build_ioff(&control->id, kctl, index_offset);
|
|
snd_ctl_build_ioff(&control->id, kctl, index_offset);
|