Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
ALSA: usb-audio: Fix NULL dererence at error path
At an error path to release URB buffers and contexts, the driver might hit a NULL dererence for u->urb pointer, when u->buffer_size has been already set but the actual URB allocation failed. Fix it by adding the NULL check of urb. Also, make sure that buffer_size is cleared after the error path or the close. Cc: <[email protected]> Reported-by: Sabri N. Ferreiro <[email protected]> Link: https://lore.kernel.org/r/CAKG+3NRjTey+fFfUEGwuxL-pi_=T4cUskYG9OzpzHytF+tzYng@mail.gmail.com Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Takashi Iwai <[email protected]>
- Loading branch information