Re: [PATCH] usb/peak_usb: cleanup code

From: Marc Kleine-Budde
Date: Wed May 11 2022 - 02:45:16 EST


On 10.05.2022 23:38:38, Bernard Zhao wrote:
> The variable fi and bi only used in branch if (!dev->prev_siblings)
> , fi & bi not kmalloc in else branch, so move kfree into branch
> if (!dev->prev_siblings),this change is to cleanup the code a bit.

Please move the variable declaration into that scope, too. Adjust the
error handling accordingly.

regards,
Marc

--
Pengutronix e.K. | Marc Kleine-Budde |
Embedded Linux | https://www.pengutronix.de |
Vertretung West/Dortmund | Phone: +49-231-2826-924 |
Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 |

Attachment: signature.asc
Description: PGP signature