diff options
Diffstat (limited to 'sound/usb/pcm.c')
-rw-r--r-- | sound/usb/pcm.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/sound/usb/pcm.c b/sound/usb/pcm.c index b0370d5f33f8..0e4e0640c504 100644 --- a/sound/usb/pcm.c +++ b/sound/usb/pcm.c @@ -160,6 +160,8 @@ static int init_pitch_v1(struct snd_usb_audio *chip, int iface, unsigned char data[1]; int err; + if (get_iface_desc(alts)->bNumEndpoints < 1) + return -EINVAL; ep = get_endpoint(alts, 0)->bEndpointAddress; data[0] = 1; |