[PATCH] net: phy: cortina: Ensure memory allocated is freed
Tom Rini
trini at konsulko.com
Sun Aug 17 17:24:42 CEST 2025
On Tue, 05 Aug 2025 17:10:26 +0100, Andrew Goodbody wrote:
> In cs4340_upload_firmware a buffer is allocated with malloc but this is
> never freed. The pointer to this buffer, addr, is not even kept
> unchanged. But in some cases addr is not a buffer allocated by malloc.
> Introduce the use of another pointer to keep track of the buffer and to
> know if it needs to be freed.
>
> This issue was found by Smatch.
>
> [...]
Applied to u-boot/next, thanks!
[1/1] net: phy: cortina: Ensure memory allocated is freed
commit: 145a6f447e47f679218f8886c06622b19f4e22a6
--
Tom
More information about the U-Boot
mailing list